7

I have an ASUS Zenbook OLED with a trackpad.

Even though this trackpad is fine, and mouse pointer movement is a good speed, the two-finger scroll is just too darn fast.

In the settings app, I can only set the pointer movement speed, not the scroll speed.

In the gnome-tweaks app, there is nothing to set the scroll speed either.

The only thing I could find is a hack that is far too drastic. (preloading a lib, and on-the-fly hacking the input events.)

A 'libinput measure' run was of no help.

I cannot find a libinput quirk attribute that would let me control scroll speed.

OS: Ubuntu 22.10

Desktop: Wayland

libinput: 1.21.0

laptop: ASUS ZenBook UX325EA

$ sudo libinput --list-devices
...
Device:           ASUE140A:00 04F3:3134 Touchpad
Kernel:           /dev/input/event6
Group:            6
Seat:             seat0, default
Size:             129x64mm
Capabilities:     pointer gesture
Tap-to-click:     disabled
Tap-and-drag:     enabled
Tap drag lock:    disabled
Left-handed:      disabled
Nat.scrolling:    disabled
Middle emulation: disabled
Calibration:      n/a
Scroll methods:   *two-finger edge 
Click methods:    *button-areas clickfinger 
Disable-w-typing: enabled
Disable-w-trackpointing: enabled
Accel profiles:   flat *adaptive
Rotation:         n/a
...
Bram
  • 3,699

4 Answers4

7

Change Scroll Speed on Linux

This works if your scroll speed is too fast or too slow. For me, it works on Ubuntu (all flavours) 22.04 but does take a few minutes to do, but its worth it. Saw it somewhere before and works for me everytime i need to do it, so can't take credit for it, but can't remember where it was. Controls scroll speed system wide, not just browser, and its what linux is all about isnt it, command line to make the system do what you want. Anyway follow it step by step and it'll work for you, but its trial and error to which speed setting works best for you.

I've taken screenshots of my cmd line so you can follow easily, but as i'm a new sign up, it says I can't post images here until I've got 10 reputation. While I wait for that, there should be links under each step (or end of post) to see the screenshot.

Step 1 Open terminal - ctrl + alt + T When terminal opens, run command to install ‘libinput-tools’ package in case you don’t have it:

sudo apt install libinput-tools

Step 1 screenshot

Step 2 Run command to get your touchpad size:

sudo libinput measure touchpad-size 100x100

You'll need to take the measurements it gives for your kernel specified touchpad size, in my case, 93.9x66.6mm (Img 2, WxH). Round your number up/down, so its a whole number and not decimals. At this stage, we only need the dimensions, DO NOT do the touchpad axis finder, do not move your finger along the touchpad yet. Ctrl + C to exit.

Step 2 screenshot

Step 3 Next we need to figure out what speed we want, so multiply your dimensions by the number you want, for example i set mine to 0.5x scroll speed, 94 x 0.5 = 47 & 66 x 0.5 = 33, so its 47x33.

Obviously i just divided the numbers in half to get 0.5 of the value, but the above is an example in case anyone wants 0.6, 0.7 etc, this also works in the opposite direction, if you want faster scroll, you can multiply by more than 1, eg 94 x 1.3. also in the screenshot below, i'm aware i put in 48 instead of 47, apologies

So we re run the command in step 2, but replace the 100x100 with your calculated dimensions, in my case its:

sudo libinput measure touchpad-size 47x33

Run the command, and now you can follow the terminal output to “Move one finger along all edges of the touchpad until the detected axis range stops changing.“

Step 3 screenshot

When finished and the axis stops changing, press Ctrl + C to finish that, and it will give us the output needed for the config file.

Step 4 After you press Ctrl + C after axis change, you'll see the following output:

Step 4 screenshot

You need to copy between both <8---------------- (Grey background in screenshot above, ive put a red box around it)

Step 5 Run the following command to open and edit config file

sudo nano /etc/udev/hwdb.d/61-evdev-local.hwdb

Paste in the lines you copied in step 4, then press Ctrl + X to save and exit. Step 5 Screenshot

Step 6

In terminal, update the hardware database by running following command:

sudo systemd-hwdb update

Run following command to reload udev rules:

sudo udevadm trigger /dev/input/event*

Step 6 Screenshot

Thats it! Now you need to reboot for it to take effect. There's a very good chance this will also slow down your pointer speed, but you just need to go to “Settings -> Mouse & Touchpad” and adjust ‘Touchpad Speed’ slider to your liking. (If it doesn't slide properly, choose on the slider line where you want it to be, hover your mouse pointer there and double click)

If you want to remove the speed you've set, and reset it back to defaults

Step 1 Open terminal, Ctrl + Alt + T, and run this command to delete the config file

sudo rm /etc/udev/hwdb.d/61-evdev-local.hwdb

Step 2 Then update database and reload udev rules by running 2 commands after the other

sudo systemd-hwdb update

then

sudo udevadm trigger /dev/input/event*

And finally, restart your computer to take effect.

It may seem a little long here, but its only because i've tried to explain it as best as i can, its actually quite easy to do, so don't be afraid, it may seem daunting, but its very easy. Best of luck!

6

I've given up on getting this to work.

Note, although I am on Ubuntu 22.10, the same issue is present on older Ubuntu versions too.

I did find a workaround by doing the scrolling per app if the app has a setting for it.

For instance, Firefox:

Go to URL about:config

Accept the risk and continue.

Then search for mousewheel.default and set the multiplier values to something lower.

enter image description here

Bram
  • 3,699
5

I have an Ubuntu 22.04 and I got it to work in chrome. got to chrome://flags/ search Windows Scrolling Personality and enable it.

0

EDIT: I'm reading by now that synaptic might not be the best solution but libinput

you might disable wayland and use xinput instead by editing the /etc/gdm3/custom.conf file, you can do a sudo nano /etc/gdm3/custom.conf and uncomment the line that has WaylandEnable=false and then restart.

Once restarted you should be able to change xinput properties. List your devices withxinput list and change the property "Synaptics Scrolling Distance":

xinput --set-prop <id> 'Synaptics Scrolling Distance' -120 -120