8

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?

Gabriel Staples
  • 11,502
  • 14
  • 97
  • 142
Dario
  • 81

2 Answers2

4

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,990
  • 1
  • 34
  • 47
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

Gabriel Staples
  • 11,502
  • 14
  • 97
  • 142