Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
touchpad fn key fix
# toggle touch pad
device=`xinput list --name-only | grep -i touchpad`
isOn=`xinput list-props "$device" | grep -i enabled | tail -c 2`
case "$isOn" in
notify-send --icon=$iconEnabled "Touchpad [ON]" "Your touchpad is now enabled"
xinput set-prop "$device" 'Device Enabled' 1
notify-send --icon=$iconDisabled "Touchpad [OFF]" "Your touchpad is now disabled"
xinput set-prop "$device" 'Device Enabled' 0
notify-send --icon=$iconEnabled --expire-time=10000 "Error: Touchpad device enabled says: $isOn."

This comment has been minimized.

Copy link
Owner Author

@v-dimitrov v-dimitrov commented Feb 4, 2014

  1. Create a new empty file and copy this code inside it; Save the file in /usr/bin/ and name this file ttp
  2. Create a new shortcut (settings > keyboard > application shortcuts) and assign it a command ttp. Choose whatever key combination you like (my case: FN + F9 since this is my non working touchpad key-combo).

Note: this fixes my problem with non working touchpad disabling button on Manjaro Linux xFCE with kernels 313-315 at the moment. My laptop is ASUS x401a.


This comment has been minimized.

Copy link

@anovsiradj anovsiradj commented Sep 3, 2018

work on my ubuntu 16.04 using xfce4.
perfect 💯 thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment