Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Disable GTK+ scrollbar zoom mode
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
defer-
Tux's lil' helper
Tux's lil' helper


Joined: 11 Jun 2007
Posts: 140
Location: Finland

PostPosted: Wed Jun 25, 2014 10:57 am    Post subject: Disable GTK+ scrollbar zoom mode Reply with quote

GTK+ has this new feature called zoom mode. When you click-and-hold or long press on the slider it will put the scrollbar into zoom mode. Then the scrollbar moves very slowly. Only half the speed of the cursor. This feature really annoyed me and everybody told me it is impossible to disable it. So i figured out how to disable it on gentoo and thought i should share the solution.

Create patch to increase the GTK+ zoom mode delay:
/etc/portage/patches/x11-libs/gtk+-3.12.2/gtk+-3.12.2-zoom-mode-delay.patch
Code:
diff -upr gtk-upstream/gtk/gtkrange.c gtk+-3.12.2/gtk/gtkrange.c
--- gtk-upstream/gtk/gtkrange.c 2014-06-24 20:55:54.429790047 +0300
+++ gtk+-3.12.2/gtk/gtkrange.c  2014-06-24 20:56:40.589789587 +0300
@@ -64,7 +64,7 @@
 #define UPDATE_DELAY        300  /* Delay for queued update */
 #define TIMEOUT_INITIAL     500
 #define TIMEOUT_REPEAT      50
-#define ZOOM_HOLD_TIME      500
+#define ZOOM_HOLD_TIME      10000
 #define AUTOSCROLL_FACTOR   20
 #define SCROLL_EDGE_SIZE 15


Set portage to call epatch_user() for all ebuilds:
/etc/portage/bashrc
Code:
post_src_unpack() {
        if type epatch_user &> /dev/null ; then
                if [[ -d ${S} ]]; then
                        pushd "${S}" 2>/dev/null
                        epatch_user
                        popd 2>/dev/null
                else
                        epatch_user
                fi
        fi
}


Rebuild GTK+:
# emerge -1 gtk+
_________________
https://github.com/defer-
Back to top
View user's profile Send private message
Allan Wegan
n00b
n00b


Joined: 06 Apr 2012
Posts: 23

PostPosted: Mon Sep 15, 2014 5:26 am    Post subject: Reply with quote

Thanks for the fix.

That "zoom mode" was the second most annoying in-ya-face-cant-be-turned-off "feature" i stumbled on.
Back to top
View user's profile Send private message
defer-
Tux's lil' helper
Tux's lil' helper


Joined: 11 Jun 2007
Posts: 140
Location: Finland

PostPosted: Sun Sep 28, 2014 4:38 pm    Post subject: Reply with quote

Yes it was annoying. I'm glad it helped.
_________________
https://github.com/defer-
Back to top
View user's profile Send private message
haarp
Guru
Guru


Joined: 31 Oct 2007
Posts: 535

PostPosted: Fri Feb 20, 2015 10:44 am    Post subject: Reply with quote

According to https://bugzilla.gnome.org/show_bug.cgi?id=728739#c9 you can also instead set
Code:
[Settings]
gtk-long-press-time = 5000

in ~/.config/gtk-3.0/settings.ini


(but only if you use newer GTK+ than 3.12)
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum