niemueller.de::home niemueller.de
Open Software. Open Knowledge.




 

Tim's WebLog


Disable warping scroll bars

Ever since Gnome 3 I was rather annoyed by the new scroll bar behavior that makes you jump to a place where you click, instead of moving one page in that direction. Most of the time, it's ok since you have a mouse wheel (and I can only guess that was the rationale behind this change) -- most of the time...

With a new laptop (and again with a trackpoint and without a scroll wheel) I was once again annoyed by this behavior and decided to look for a fix. And I found one.

The feature is called "primary button warps slider" and is present in Gtk2 and Gtk3. With Gtk 3 the default changed the default to set it to on. At least on Fedora, the Gtk2 theme also overrides it to set it to true. So the fix is to disable it for Gtk3 and Gtk2 (the latter is crucial to fix it in Firefox).

For Gtk3, edit or create ~/.config/gtk-3.0/settings.ini and add or set:

[Settings]
gtk-primary-button-warps-slider = false

For Gtk2 there is a small catch, edit ~/.gnome2/gtkrc-2.0. Not that editing ~/.gtkrc-2.0 does not work. The reason is that the latter is read before the theme file and consequently settings made there are overwritten, while the one in the ~/.gnome2 directory is read after the theme and allows to overwrite theme values. Thanks to the strace tool for helping me find this. So, fixing Gtk2 is then as simple as adding:

gtk-primary-button-warps-slider = 0

Note that it indeed needs to be zero, false does not work here.

I would guess this should be something for the awesome gnome-tweak-tool.

Update: Turns out that the Gtk2 trick with the ~/.gnome2/gtkrc-2.0 only worked on older versions. I had done the modifications on F20 and F22 at the same time. There seems to be no gtkrc file read after the theme file on F22 (according to strace logs). Therefore, the only way to fix this for Gtk2 (e.g., Thunderbird) on F22 is to modify the theme file. Pity!

Comments for this posting

Do you know that you can right click on the scroll bar to have the "scroll one page" behavior that you seek for? Left mouse button jumps to exact location (I personally love that), right mouse button moves by page up or down.





Top 5 Pages
Wiki
WebLog
Friends' blogs
Onager
SquidGuard Webmin Module




Palm Software
UniMatrix UniMensa UniSorter
UniChat OHS Mobile Onager


My Bookshelf




Valid XHTML 1.1!

RSS Copyright © 2000-2016 by Tim Niemueller