6

Now when I scroll up or down by one tick, the text moves up and down by 5 lines, which is not what I want. How do I change that number to 1? Is it even possible?

Dario
  • 61
  • For fresh installations, I need to re-plug my mouse (one time) to achieve the desired result. – pa4080 Sep 08 '19 at 09:07

2 Answers2

3

The scrolling speed is hardwired in the source. There's no config option to modify it, your only chance is to modify the source and rebuild it.

You'll need to modify this line of Ubuntu package libvte-2.91-0 (source package: vte2.91) to contain v = 1.0; instead.

Please refer to other sources describing how to patch and recompile an Ubuntu package. Once the new package is installed, you need to quit all gnome-terminal windows at once for the change to take effect.

egmont
  • 8,225
  • Why? Scrolling distance is globally adjustable in evdev and libinput. But not in a specific app. – Pilot6 Sep 08 '19 at 09:06
  • 1
    @Pilot6 "by one tick" the question apparently goes for regular mouse wheels. Could you please enlighten me how the device driver can be configured to report something else then? – egmont Sep 08 '19 at 09:08
  • I mean that xinput can be configured. – Pilot6 Sep 08 '19 at 09:09
  • See also https://bugzilla.gnome.org/show_bug.cgi?id=748012 and https://bugzilla.gnome.org/show_bug.cgi?id=769696, any help that would let us properly fix those issues is highly appreciated – over there in bugzilla, please. – egmont Sep 08 '19 at 09:09
  • @Pilot6 Could you please be a little more specific? – egmont Sep 08 '19 at 09:10
  • It looks that I was wrong. https://www.mankier.com/4/evdev It is integer, you can't reduce it there. – Pilot6 Sep 08 '19 at 09:16
0

Tested in Ubuntu 22.04 with gnome-terminal --version 3.44.0. I believe you must use the x11 window manager, not Wayland, as well, which requires clicking the little gear icon to select the window manager when logging in.

You can change the scroll speed of any program on Linux using imwheel. Here is how to do it for gnome-terminal. In the example below, I multiply the default scroll speed by a factor of 2, which is a good setting I personally like for gnome-terminal.

Modified from my answer here: How to permanently fix scroll speed in Chrome, Sublime Text, Foxit PDF reader, and any other application you see fit.

sudo apt update
sudo apt install imwheel
gedit ~/.imwheelrc

Copy and paste the following into the newly-created .imwheelrc file (that you just made in your home directory via the gedit command above):

# For the `gnome-terminal` default shell/terminal that comes with Ubuntu
"gnome-terminal"
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

2 is the "scroll speed multiplier." Use a larger number for faster scrolling, or a smaller number for slower scrolling. The "gnome-terminal" part says to apply these scroll wheel speed increase changes ONLY to gnome-terminal.

Next (as explained in my answer above), do this:

Run imwheel -b "4 5" to test your settings. When done testing, run killall imwheel to kill it, then make your edits to .imwheelrc, as desired, and run imwheel -b "4 5" again for more testing.

Also keep in mind that if you are using a cheap mouse, your scroll wheel decoder may be lousy and miss encoder counts when moving the wheel fast. Therefore, in such a case, move the wheel at a reduced speed when testing the effect of imwheel, so that your mouse doesn't miss encoder counts on the scroll wheel, making you think imwheel isn't working right when it's really just your cheap hardware's problem.

Add imwheel -b "4 5" to Ubuntu's "Startup Applications" to get it to run every time the computer starts.

See my answer above for more details.

Here is my file from my eRCaGuy_dotfiles repo: .imwheelrc