Version: (using Devel) Installed from: Compiled sources OS: Linux I have counted three different actions for the mouse wheel inside a konsole window, each depends on the amount of scrollback. 1. No scrolling Mouse up = bash history Mouse down = bash history 2. Small amount of scrolling (say 2 viewports high) Mouse up = bash history + scroll up, this wraps at the top (ie. scroll all the way up and you are placed back at the bottom) Mouse down = bash history, unless at bottom of scroll, in which case nothing 3. Lots of scrolling (over limit) Mouse up = scroll up Mouse down = scroll down
Cases (1) and (3) are by design. Case (2) is a bug which was fixed yesterday. If the scrollbar thumb has any room to move then mousewheel events scroll through Konsole's output. The reason mouse up / mouse down goes through bash's history is because the terminal sends Up/Down key presses to the terminal on mouse wheel if it cannot scroll - see bug# 159340
Bug 159340 says that each mouse click = 3 presses of the button which is not very useful for bash history. Could this feature be disabled for bash? Or maybe configurable? Comment #2 on that bug sounds like a better solution it also shows that you are within the application rather than in your shell as before. Scrolling whilst watching top looks strange and if that could be put into a special frame then it would not scroll.
> says that each mouse click = 3 presses of the button which > is not very useful for bash history. Indeed not. It practise it depends whether this accidental side-effect is annoying or not. I haven't really run into it accidentally since implementing it myself. > Scrolling whilst watching top looks strange and if that > could be put into a special frame then it would not scroll. If by "special frame" you mean the 'alternate screen', which is used by Vim, Screen and other interactive applications, then it is up to the terminal application itself to decide whether it uses it or not.
Now that I know the symptoms, I have seen it before when scrolling through tabs when I accidentally move my mouse over the application area. Would it be possible to do a few things? 1. Add some notification when the alternate screen is showing (something like the Ctrl+s notification - which I really like) - maybe something like 'You are now in an interactive application, mouse wheel is enabled' 2. Make mouse only send keypresses when in this mode. Is the problem that less does not inform you that is interactive and this is a workaround for that?
> maybe something like 'You are now in an interactive application, > mouse wheel is enabled' That I'm sure would annoy a lot of people, myself included. I'm going to stick with this as it is now. If it gets reported again in future I might revisit it.