edit: I can achieve point 1 now. Still need a solution for point 2, though.

I am having a hard time configuring my notebook's touchpad.

The touchpad already works. It successfully responds to one-finger tap, two-finger tap and two-finger vertical scrolling.

What I want to accomplish:

  1. change two-finger tap action from right-mouse click to middle-mouse click
  2. add three-finger tap functionality to yield right-mouse click action (i have checked that the three-finger tap is supported by my laptop's touchpad since it works on Windows)

I read on a forum to use this as a guide.

I have successfully accomplished point 1 with synclient TapButton2=2. However, I have to do it everytime I log in. I have tried to put that command on /etc/rc.local but the computer always boots and logins with the default configuration.

Regarding point 2, I have tried synclient TapButton3=3 but it doesn't do anything when I three-finger tap the touchpad.

I am running Ubuntu 11.10 on an Asus N82JV.


nuno@mozart:~$ cat /etc/X11/xorg.conf  Section "InputClass"
        Identifier "touchpad catchall"
        Driver "synaptics"
        MatchIsTouchpad "on"        MatchDevicePath "/dev/input/event*"             Option "TapButton1" "1"             Option "TapButton2" "2"             Option "TapButton3" "3" EndSection


nuno@mozart:~$ cat /usr/share/X11/xorg.conf.d/50-synaptics.conf
# Example xorg.conf.d snippet that assigns the touchpad driver
# to all touchpads. See xorg.conf.d(5) for more information on
# InputClass.
# DO NOT EDIT THIS FILE, your distribution will likely overwrite
# it when updating. Copy (and rename) this file into
# /etc/X11/xorg.conf.d first.
# Additional options may be added in the form of
#   Option "OptionName" "value"
Section "InputClass"
        Identifier "touchpad catchall"
        Driver "synaptics"
        MatchIsTouchpad "on"
        MatchDevicePath "/dev/input/event*"
            Option "TapButton1" "1"
            Option "TapButton2" "2"
            Option "TapButton3" "3"

xinput list:

nuno@mozart:~$ xinput list
⎡ Virtual core pointer                      id=2    [master pointer  (3)]
⎜   ↳ Virtual core XTEST pointer                id=4    [slave  pointer  (2)]
⎜   ↳ Microsoft Microsoft® Nano Transceiver v2.0    id=12   [slave  pointer  (2)]
⎜   ↳ Microsoft Microsoft® Nano Transceiver v2.0    id=13   [slave  pointer  (2)]
⎜   ↳ ETPS/2 Elantech Touchpad                  id=16   [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)]
    ↳ Video Bus                                 id=8    [slave  keyboard (3)]
    ↳ Sleep Button                              id=9    [slave  keyboard (3)]
    ↳ USB2.0 2.0M UVC WebCam                    id=10   [slave  keyboard (3)]
    ↳ Microsoft Microsoft® Nano Transceiver v2.0    id=11   [slave  keyboard (3)]
    ↳ Asus Laptop extra buttons                 id=14   [slave  keyboard (3)]
    ↳ AT Translated Set 2 keyboard              id=15   [slave  keyboard (3)]
  • 1
    please post the output of xinput list – martin Nov 25 '11 at 23:52
  • 1
    In Ubuntu, the file corresponding to ArchLinux's /etc/X11/xorg.conf.d/10-synaptics.conf is /usr/share/X11/xorg.conf.d/50-synaptics.conf. Also, pacman is the command-line program for ArchLinux's package manager, so you cannot meaningfully use it in Ubuntu. The command corresponding to ArchLinux's pacman -S xf86-input-synaptics in Ubuntu is sudo apt-get install xserver-xorg-input-synaptics; however, in Ubuntu that driver package is installed out of the box, so it is neither necessary nor helpful to actually run that command. – Eliah Kagan Nov 26 '11 at 1:56
  • Does this work? askubuntu.com/questions/81805/… – jrg Nov 26 '11 at 2:17
  • That question has an answer for a touchpad that doesn't work. My touchpad already does. I need help configuring it. – nunos Nov 29 '11 at 1:30
  • @nunos alright, understood. Thanks for answering. :) – jrg Dec 1 '11 at 2:09

This seems to work (for part 1) even when you hibernate or sleep.

echo synclient TapButton2=2 TapButton3=3 >> ~/touchpad_settings.sh
chmod +x ~/touchpad_settings.sh
gsettings set org.gnome.settings-daemon.peripherals.input-devices hotplug-command "/home/YOUR USER NAME/touchpad_settings.sh"

Make sure to replace YOUR USER NAME with your actual user name. This was pulled from http://tombuntu.com/index.php/2011/11/06/persistent-touchpad-configuration-in-ubuntu-11-10/

  • that worked out perfectly. Please consider answering point 2, so that I can accept your answer. Thanks. – nunos Dec 9 '11 at 22:51
  • TapButton3=3 should take care of #2, but it doesn't. TapButton3 is the 3-finger tap and =3 sets it to right click. I have an Asus and it just doesn't happen. I think that particular issue is driver related. – Greg Dec 12 '11 at 21:48
  • 1
    TapButton3=3 probably does not work due to this Unity bug: bugs.launchpad.net/unity/+bug/839769 – n3rd Jan 17 '12 at 15:42

For setting the two finger tap for the middle button you can do the following.

Open start-up application start-up application

and add a new programm; command line

name it, enter in the command line the following command:

xterm -e synclient "synclient TapButton2=2"

and save it.

For the three finger tap; are you sure that your touch pad support multiple finger actions, as for example my touchpad just emulate the two finger actions and I found no way so far to emulate three fingers

  • I am sure the touchpad supports three-finger tap since I have used it on windows. – nunos Dec 1 '11 at 17:35
  • thanks for your reply. it is working when I boot the computer after a shutdown. However, if I boot it up after a hibernate it goes back to the previous configuration.. – nunos Dec 1 '11 at 17:36
  • and how is it after wake up from sleep? Sorry my changes are kept also after hibernate. – dago Dec 2 '11 at 22:43
  • if with sleep you mean suspend (s2ram) I can't answer you that, since it that funcionality isn't working properly with my notebook. – nunos Dec 3 '11 at 1:39

Are you using Unity? Because on my netbook, 3 finger gestures are working in Gnome Shell, but not in Unity. Since I wanted to use this kind of gestures in Unity, I looked at its source code and found out that it is Unity itself that is blocking out the 3 fingers gestures. But it turns out that it's possible to fix it. I posted detailed instruction on how I did it in the post How can I disable arbitrary default multitouch gestures in Unity?.

With these changes, 3 finger taps work right away for me, and are automatically assigned to a middle-click, without the need for a startup program. Well, it's the reverse of the mapping you're looking for regarding middle clicks and right clicks, but you seem to have gathered enough information so far to handle the switch.

However, you might be interested in a program called touchegg to remap your touches. It allows you to do many more things than you could do with synconf, such as defining different custom touchpad gestures for your different programs, such as a 3 finger drag to the left or the right to go back or forward in your browser's history. That's to use that program that I patched Unity in the first place. And it is very simple to configure. You can install it by typing

sudo apt-get install touchegg

Check out the demonstration video on the website.

On a last note, if Unity is for you, as it is for me, the reason why you couldn't use 3 finger gestures, then you will probably have no choice but to re-patch and recompile the unity package when it is updated.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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