The Taming of The Mouse – Details of Mouse Setup in X

After upgrade to  the new version of Linux (Mint 13, which is based on Ubuntu Precise) I’d found that my trackpoint is not working right (on Dell E6410), it was bit unresponsive and movement was not smooth.   Touchpad was generally  OK, but trackpoint really sucked. So I had to look into details of mouse setup in X and I was really surprised how many various parameters are there and how many aspects of mouse behaviour could be modified.   So I’d like to share few tips how to set pointing device – apart of those obvious settings, which are available in desktop settings (Acceleration and Sensitivity).

First of all the desktop setup (Mouse and TouchPad in Gnome/Cinnamon/Unity) was not working for trackpoint, because trackpoint basically another pointer device and setup works reasonably only for  touchpad and external mouse (at least in my case).   So we  have to configure trackpoint manually.

First step is to find right input device – here the xinput tool can help us,   if runs without any parameters it lists all available input devices:

We can see that the trackpoint device is called “DualPoint Stick” and has id 11. Now we can start to play with its settings, here again xinput will help. We need to find what parameters we can set for this device:

To influence cursor movement these 4 properties are of interest:
Device Accel Profile – this is most important parameter, because it set  an algorithm for cursor behaviour – how it accelerates  and decelerates based on mouse movement.  I have found that profile 2 – polynomial is most appropriate for me.   Also default profile 0 can behave well for trackpoint, but I have found one flaw –  this profile is dependent on threshold value (the desktop setting window calls it Sensitivity) that is set by xset mouse – and this value is common for several pointer devices, so if you optimize your trackpoint for profile 0,  and then you go to touchpad settings and change Sensitivity value there, your trackpoint settings get suboptimal again.  So profile 2 can assure completely independent control of  this device.
Device Accel Constant Deceleration and Device Accel Adaptive Deceleration parameters controls how cursor will slow down and are quite important for precise movement.  Especially Adaptive Deceleration is worth to play with.
Device Accel Velocity Scaling basically influences how sensitive cursor is to mouse movements and determines sampling rate of mouse movement.
Very detailed and profound explanation of  how these parameters works and how they should be set up can be found here.

To find optimal parameters we have to play with them for a while – using xinput set-prop – the mouse reacts immediately after property is changed. Property can be referenced either by name or id – I’ve found using ids easier. So we can try something like this:

When we’re done with tests we have to make these changes permanent, best way is to create device specific config file  /etc/X11/xorg.conf.d/90-evdev-trackpoint.conf that looks like this:

2 thoughts on “The Taming of The Mouse – Details of Mouse Setup in X”

  1. I cannot thank you enough!! Your post has been a life-saver for me. THANKS, THANKS, THANKS.

    The idionsincratic trackpad in my Dell Latittitude E5510 has been driving me mad for months!

    The trackpad on my Thinkpad T61 has always been much better behaved.

    I use Debian with Gnome3.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">