
Linux Laptop Mouse Hacks

I’m not certain which websites I pulled these hints from, but they are not mine. But I do want to keep them in case I ever lose my system settings and need to get back to it again.
Annoying accidental "clicks"
I hate laptop touchpads, they have the annoying habit of clicking from a minute touch when you are typing. This is a very annoying thing to happen when you are in a GUI text editor. To combat this with a synaptics touchpad, you can use the tool called syndaemon. Here’s the description from the man page
NAME
syndaemon - a program that monitors keyboard activity and disables the touchpad when the keyboard is being used.
SYNTAX
syndaemon [-i idle-time] [-d]
DESCRIPTION
Disabling the touchpad while typing avoids unwanted movements of the pointer that could lead to giving focus to the wrong window. This program needs SHMConfig “on” in your XFree86 Synaptics Touchpad configuration.
OPTIONS
-i How many seconds to wait after the last key press before enabling the touchpad. (default is 2s).
-d Start as a daemon, ie in the background.
-t Only disable tapping, not mouse movements, in response to keyboard activity.
Now personally 2 seconds is a bit much for me and takes away a bit of responsiveness. So I use the -i .4 option to wait .4 seonds after the last keypress to allow movement.
You may want to create it as a session item in gnome so that when you log in, it automatically is there. Using the session editor under System » Preferences » Personal » Sessions Add a New Startup Program.
Name Synaptics Touchpad Daemon
Command /usr/bin/syndaemon -i .4 -d
This will help stop those anoying accidental mouse clicks. Don’t forget to put SHMConfig “on” in your xorg.conf!
Disable Touchpad on USB Mouse Insertion
If you are using a system with udev (dynamic device management) you can create rules that execute programs when an action occurs.
So if like me, you want the touchpad disabled when you plug in a usb mouse you can add these lines to your /etc/udev/rules.d/50-udev.rules file under the #input devices section
KERNEL=="mouse2", ACTION=="add", RUN="/usr/bin/synclient TouchpadOff=1", NAME=input/%k", MODE="0644" KERNEL=="mouse2", ACTION=="remove", RUN="/usr/bin/synclient TouchpadOff=0"
This will disable and re-enable your touchpad when you plug in a usb mouse.

