SpeedUp Mouse Wheel on Linux

Increase wheel speed on Linux using imwheel. This will make scrolling easier, while use Chromium, Firefox, LibreOffice, viewing pdf files in Evince.

 

1. Install imwheel

apt install imwheel

 

2. Check the applications names

Check the names of applications that should be affected by imwheel settings. Run in terminal:

xprop WM_CLASS | grep -o '"[^"]*"' | head -n1

And click on the window you want to know the name of. It will print "libreoffice", or "chromium", or "evince", or "firefox".

 

3. Create config file

My example for speed up wheel with multiplier 4.

Button4 - moving wheel up. Button5 - moving wheel down.

~$ cat ~/.imwheelrc 

#Button4 - button #4, ', 4' - speed multiplier
#other lines for scale using Ctrl + wheel
#firefox - Navigator
"chromium|evince"
None,      Up,   Button4, 4
None,      Down, Button5, 4
Control_L, Up,   Control_L|Button4
Control_L, Down, Control_L|Button5
Shift_L,   Up,   Shift_L|Button4
Shift_L,   Down, Shift_L|Button5
Control_R, Up,   Control_R|Button4
Control_R, Down, Control_R|Button5
Shift_R,   Up,   Shift_R|Button4
Shift_R,   Down, Shift_R|Button5

"geany|libreoffice"
None,      Up,   Button4, 2
None,      Down, Button5, 2
Control_L, Up,   Control_L|Button4
Control_L, Down, Control_L|Button5
Shift_L,   Up,   Shift_L|Button4
Shift_L,   Down, Shift_L|Button5
Control_R, Up,   Control_R|Button4
Control_R, Down, Control_R|Button5
Shift_R,   Up,   Shift_R|Button4
Shift_R,   Down, Shift_R|Button5

#"Navigator"
".*"
None,      Up,   Button4, 1
None,      Down, Button5, 1
Control_L, Up,   Control_L|Button4
Control_L, Down, Control_L|Button5
Shift_L,   Up,   Shift_L|Button4
Shift_L,   Down, Shift_L|Button5
Control_R, Up,   Control_R|Button4
Control_R, Down, Control_R|Button5
Shift_R,   Up,   Shift_R|Button4
Shift_R,   Down, Shift_R|Button5

Here, I defined settings for chromium, firefox (xprop says it is Navigator), libreoffice, evince, geany using "|" as logical OR and using ".*" for all other applications. The name of application could have any other regular expression.

 

4. Run imwheel and kill. And add to startup

Run in terminal:

imwheel -b "4 5"

This will use config file ~/.imwheelrc and will only affect Button4 and Button5 as we defined by option '-b'.

Kill for reconfigure:

pkill -f imwheel

Add to startup. I use Xfce4, then I will click Applications button -> Settings -> Settings Manager -> Session and Startup -> Application Autostart, and there +. Name: imwheel, Command: 

/usr/bin/imwheel -b "4 5"

There are also other ways to add to startup, check links for other ways. Note that adding `imwheel -b "4 5"` to ~/.xinitrc did not work.

 

Links

1. Permanently fix Chrome scroll speed. Answer by Gabriel Staples https://askubuntu.com/questions/254367/permanently-fix-chrome-scroll-sp…

2. Imwheel on ArchLinux wiki https://wiki.archlinux.org/title/IMWheel

Section
Category