I'm running Ubuntu 16.04 and would like to invert my touchpad scrolling so that moving my two fingers towards the monitor causes the screen to scroll up. Previously, there used to be an option in mouse and touchpad settings that allowed for this. Similarly, gsettings indicates that touchpad configurations are deprecated. Thoughts?

Edit: the xinput command gives this output:

Virtual core pointer                        id=2    [master pointer  (3)]  
⎜   ↳ Virtual core XTEST pointer                id=4    [slave  pointer  (2)]  
⎜   ↳ ImPS/2 Generic Wheel Mouse                id=14   [slave  pointer  (2)]  
⎣ Virtual core keyboard                     id=3    [master keyboard (2)]  
    ↳ Virtual core XTEST keyboard               id=5    [slave  keyboard (3)]  
    ↳ Power Button                              id=6    [slave  keyboard (3)]  
    ↳ Video Bus                                 id=7    [slave  keyboard (3)]  
    ↳ Power Button                              id=8    [slave  keyboard (3)]  
    ↳ Sleep Button                              id=9    [slave  keyboard (3)]  
    ↳ Integrated_Webcam_HD                      id=10   [slave  keyboard (3)]  
    ↳ AT Translated Set 2 keyboard              id=13   [slave  keyboard (3)]  
    ↳ DELL Wireless hotkeys                     id=15   [slave  keyboard (3)]  
    ↳ Dell WMI hotkeys                          id=16   [slave  keyboard (3)]  

For some reason, I don't see a trackpad listed. I'm on a Dell Latitude E5570 laptop that definitely has a trackpad. Additionally, no mouse and trackpad options appear to support the trackpad.

Also, looking at the directory /usr/share/X11/xorg.conf.d/, I only see these configuration files:

  • Are you using xorg-synaptics or libinput?
    – Pilot6
    Sep 1 '16 at 15:42
  • I appear to have packages for both installed. I'm not sure how to check which are in use. I'm running a fairly clean 16.04 install, so I doubt I've changed the default.
    – dasconnor
    Sep 1 '16 at 15:55
  • libinput is not installed, so it is not an issue. It looks like your touchpad is not supported. Does scrolling work at all?
    – Pilot6
    Sep 1 '16 at 17:22
  • Yep, two finger scrolling works as you'd expect it. It's a fully functional trackpad.
    – dasconnor
    Sep 1 '16 at 17:23
  • It is weird. It is detected as a mouse. Do you have a mouse attached?
    – Pilot6
    Sep 1 '16 at 17:25

The option to invert scrolling directions is called Natural Scrolling and is still present in 16.04's System Settings → Mouse & Touchpad configuration.

enter image description here

  • 1
    With libinput this option is not there.
    – Pilot6
    Sep 1 '16 at 16:11
  • 1
    I used this setting a week ago. This morning scrolling no longer works and this option is gone. Was there an update released changing this?
    – mikabytes
    Jan 1 '17 at 9:44
  • @Mika No idea, I'm not aware of any updates regarding this. For me it still looks the same (running 16.04)
    – Byte Commander
    Jan 1 '17 at 15:00
  • 1
    I have no idea what happened but I managed to solve it by deleting my .config folder. After a reboot, the option reappeared and things are working now. Strange. If anyone else has this issue, please remember that deleting .config folder will remove ALL your settings...
    – mikabytes
    Jan 2 '17 at 8:49
  • 1
    Moving my ~/.config/ folder and rebooting did not work for me on Ubuntu 16.04. There is no Natural scrolling option when you have a mouse. Feb 28 '17 at 4:32

If you are using libinput, the GUI options are not available.

In this case you can enable "Natural Scrolling" by adding

Option  "NaturalScrolling" "True"

to the touchpad section of /usr/share/X11/xorg.conf.d/90-libinput.conf file.

  • 2
    That config file didn't actually exist for me. I assume that it had a nontrivial format, so I didn't go ahead and try to create it . I posted that directory's contents in my edit.
    – dasconnor
    Sep 1 '16 at 17:19

If you use libinput, then add a config file to /etc/X11/xorg.conf.d/ such as 20-touchpad.conf with this content:

Section "InputClass"
    Identifier "libinput touchpad catchall"
        MatchIsTouchpad "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"

        Option "NaturalScrolling" "on"

There are other useful features such as:

        Option "MiddleEmulation" "on"
        Option "Tapping" "on"
        Option "DisableWhileTyping" "on"

If you like, this can also be enabled for any mice with the following content in 30-pointer.conf

Section "InputClass"
        Identifier "libinput pointer catchall"
        MatchIsPointer "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"

        Option "NaturalScrolling" "on"

More info man libinput.

  • For me on Ubuntu 20.04 with Unity, the file to edit was called 40-libinput.conf, not 20-touchpad.conf.
    – Garrett
    Jul 16 at 5:37

If you install the touchpad-indicator using Synaptic, it has a natural scrolling option.

Start Synaptic from the dashboard, click the RELOAD icon, then type touchpad into the search box. Then mark the touchpad-indicator for install, then click the APPLY icon.

Let us know how you do. Cheers, Al

Not the answer you're looking for? Browse other questions tagged or ask your own question.