Disabling touchpad on Dell Latitude with XFCE

Rick Stevens ricks at nerd.com
Tue Nov 8 01:39:10 UTC 2011

On 11/07/2011 03:32 PM, suvayu ali wrote:
> Hello Oliver,
> On Mon, Nov 7, 2011 at 23:45, Oliver Ruebenacker <curoli at gmail.com> wrote:
>> I got a new Dell Latitude laptop with a touchpad and installed a
>> fresh F15-XFCE. The computer is difficult to use, because it is almost
>> impossible to type anything without touching the touchpad, and the
>> slightest touch will result in a unwanted and sometimes disastrous
>> mouse click (in contrast with the mouse keys, which need to be pressed
>> rather forcefully).
> I am not sure the gpointing-device-settings utility works any more. But
> to disable "double tap to click", you can try this in a terminal.
> $ synclient TapButton1=0
> To get a list of all the options just type synclient.
> To execute this everytime you login to XFCE put it in
> ~/.config/xfce4/xinitrc as a shell script.
> $ cat ~/.config/xfce4/xinitrc
> #!/bin/sh
> synclient TapButton1=0
> Hope this helps.

May not, as not all Dells use a Synaptics touchpad.  My Dell Inspiron
N7110 doesn't.  So, here's what I did:

1. Create "/usr/local/bin/flipdelltouchpad" containing the following
shell script:
------------------------------ CUT HERE -----------------------------
touchpadString="PS/2 Generic Mouse"
touchpadID=$(xinput list | grep "$touchpadString" | awk -F " " '{print
$6}' | awk -F "=" '{print $2}')
touchpadEnabled=$(xinput list-props $touchpadID | grep "Device Enabled"
| awk -F ":" '{print $2}')
# Check for arguments on the command line
if [ $# -eq 1 ]; then			# Any arguments?
    arg1=$(echo $1 | tr [:upper:] [:lower:])
					# Yes, convert to lower case
    cliArg=1				# Set flag that we have one
else					# There is no argument.
    cliArg=0				# Clear flag

if [ $cliArg -eq 1 ]; then		# Did we get an argument?
    if [ $arg1 = 'on' ]; then		# Yes, was it "on"?
	xinput --set-prop $touchpadID "Device Enabled" 1
					# Yes, enable the touchpad
    elif [ $arg1 = 'off' ]; then	# No, was it "off"?
	xinput --set-prop $touchpadID "Device Enabled" 0
					# Yes, disable the touchpad
    else				# None of the above, so...
	sleep 1				# ...sleep one second, exit

else					# No argument, toggle state
    if [ $touchpadEnabled -eq 1 ]; then	# Enabled now?
	xinput --set-prop $touchpadID "Device Enabled" 0
					# Yes, so disable it
    else				# Must be disabled, so...
	xinput --set-prop $touchpadID "Device Enabled" 1
					# ...enable it
------------------------------ CUT HERE -----------------------------
(code borrowed from Brendan Dugan, give props where they're due).

2. Save the file and chmod it 755 so it can be executed.

3. Go into Applications->Keyboard and select the "Application Shortcuts"

4. Add a new keystroke (I used Fn-F3 which will toggle the touchpad on
and off under Winblows but is ignored in Xfce) and tell it to run that
/usr/local/bin/dellfliptouchpad script when that key is hit.

Then, when you hold down "Fn" and press "F3", the touchpad will toggle
on and off.  The script also supports passing in an argument, too, so

	/usr/local/bin/flipdelltouchpad on

will enable the touchpad and

	/usr/local/bin/flipdelltouchpad off

will disable it.

Note that on my Inspiron this does not turn the LED on and off, but
that's a small price to pay.  I'll sort that out sometime, but for
now I'm happy.
- Rick Stevens, Systems Engineer, C2 Hosting          ricks at nerd.com -
- AIM/Skype: therps2        ICQ: 22643734            Yahoo: origrps2 -
-                                                                    -
-         The world is coming to an end ... SAVE YOUR FILES!!!       -

More information about the users mailing list