Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
script to set synaptics configuration for Thinkpad T440p
#!/bin/sh
# this script sets some parameters to get a useable configuration
# these changes are not persistent, you may want to include this in your autostart
# 1 finger = left click, 2 finger = right click, 3 finger = middle click
synclient TapButton2=3
synclient TapButton3=2
synclient ClickFinger2=3
synclient ClickFinger3=2
# enable horizontal two-finger scrolling (vertical is enabled by default)
synclient HorizTwoFingerScroll=1
# disable the top edge of the touchpad to prevent jittering when using the trackpoint
synclient AreaTopEdge=2500
# configure trackpoint buttons
synclient RightButtonAreaLeft=3700
synclient RightButtonAreaRight=0
synclient RightButtonAreaTop=0
synclient RightButtonAreaBottom=2300
synclient MiddleButtonAreaLeft=2900
synclient MiddleButtonAreaRight=3500
synclient MiddleButtonAreaTop=0
synclient MiddleButtonAreaBottom=2300
@chetankothari

This comment has been minimized.

Copy link

chetankothari commented May 20, 2014

Hey how can i switch the buttons
The default setting is
Left Middle Right
I want to change it to
Right Middle Left

And the middle button scroll is not working. Any solution to get it working.

@tfg13

This comment has been minimized.

Copy link
Owner Author

tfg13 commented May 22, 2014

you should probably change the coordinates of the "RightButtonArea"s in the last section but beware I spent quite some time figuring this out

not sure about middle button scrolling - sry, I just never used that

@chetankothari

This comment has been minimized.

Copy link

chetankothari commented May 28, 2014

Thank you @tfg13 I figured it out.

@jjekircp

This comment has been minimized.

Copy link

jjekircp commented Jul 21, 2014

On my Ubuntu 12.04 LTS system I had to change AreaTopEdge from 2500 to 100, but otherwise this works great! Thanks!
Also I don't have either vertical or horizontal scrolling (despite also enabling VertTwoFingerScroll with synclient). No worries; I'll figure out how to get the middle-button TrackPoint scroll working which I prefer (which is not difficult either).

@aloiscochard

This comment has been minimized.

Copy link

aloiscochard commented Aug 30, 2014

Instead of creating a start script, it's better to store this in a config file for X11.

For example in /etc/X11/xorg.conf.d/50-synaptics.conf (this is for Archlinux, the path might be slighty different for ubuntu.

Here is the translated content:

Section "InputClass"
    Identifier "touchpad"
    Driver "synaptics"
    MatchIsTouchpad "on"
      #1 finger = left click, 2 finger = right click, 3 finger = middle click 
      Option "TapButton2"   "3"
      Option "TapButton3"   "2"
      Option "ClickFinger2" "3"
      Option "ClickFinger3" "2"

      # enable horizontal two-finger scrolling (vertical is enabled by default)
      Option "HorizTwoFingerScroll" "1"

      # disable the top edge of the touchpad to prevent jittering when using the trackpoint
      Option "AreaTopEdge" "2500"

      # configure trackpoint buttons
      Option "RightButtonAreaLeft"    "3700"
      Option "RightButtonAreaRight"   "0"
      Option "RightButtonAreaTop"     "0"
      Option "RightButtonAreaBottom"  "2300"
      Option "MiddleButtonAreaLeft"   "2900"
      Option "MiddleButtonAreaRight"  "3500"
      Option "MiddleButtonAreaTop"    "0"
      Option "MiddleButtonAreaBottom" "2300"

EndSection

Thanks so much for that... this touchpad was driving me nuts!

@bbraybrook

This comment has been minimized.

Copy link

bbraybrook commented Feb 5, 2015

thanks for this tfg13.

if you just use the script and get an "integer parameter out of range" error, you may need to move the MiddleButtonAreaRight directive about the MiddleButtonAreaLeft directive.

If you want to disable the touchpad for cursor movement (if you only use the nub mouse), but keep the click buttons and right edge scrolling, add:
synclient AreaLeftEdge=4826 (or whatever the value of RightEdge is as shown by synclient -l)

@csarven

This comment has been minimized.

Copy link

csarven commented Feb 20, 2015

I've been using

      Option "MiddleButtonAreaLeft"   "2900"
      Option "MiddleButtonAreaRight"  "3500"

over a year now. However, I've just experienced the out or range error for some reason, as mentioned by @bbraybrook . I can confirm that if I change the swap those two lines, the error goes away.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.