Set mouse pointer resolution a.k.a sensitivity interactively?

Simon Thum simon.thum at gmx.de
Wed Jan 7 05:34:35 PST 2015


On 01/05/2015 11:03 PM, Hi-Angel wrote:
> On Mon, Jan 05, 2015 at 08:43:41PM +0100, Simon Thum wrote:
>> You can use xinput properties, those can also be set via inputclass sections
>> if I'm not mistaken.
>>
>> man xinput should get you to it, if not install xinput. Two optionas can be
>> used to achive what you describe:
>>
>> Coordinate Transformation Matrix (140): 1.000000, 0.000000, 0.000000,
>> 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
> Simon Thum, man, I love you, thank you very much! You solved the
> problem! From reading a docs I didn't understood wholly the matrix,
> though. Suppose I set the values of the diagonal that accords to x and
> y to 2. Then we'd have:
>
> ⎡ 2 0 0 ⎤   ⎡ 1 ⎤   ⎡  2  ⎤
> ⎜ 0 2 0 ⎥ · ⎜ 1 ⎥ = ⎜  2  ⎥
> ⎣ 0 0 1 ⎦   ⎣ 1 ⎦   ⎣  1  ⎦
>
> The cursor couldn't appear now in the first pixels of the screen! I am
> not sure that this is true…

Hi,

this is a possible side effect. With such a scale you are "skipping" 
pixels and the confinement MAY prevent you from reaching the edges. 
Although that would be a bug in itself, it's a pretty arcane use case. 
Normally you would use a device with sufficient precision.

If you are OK with "quasi-constant acceleration" but still want the 
precision, have a look at the adaptive deceleration feature. I use an 
adaptive deceleration of 3, if you sometimes need to hit a pixel-perfect 
location it's invaluable.

HTH


> Anyway, to sum up the steps to increase the resolution (or, at least,
> the pointer speed):
>
> $ xinput list #to list a devices
> ⎡ Virtual core pointer                          id=2    [master
> pointer  (3)]
> ⎜   ↳ Virtual core XTEST pointer                id=4    [slave
> pointer  (2)]
> ⎜   ↳ PixArt USB Optical Mouse                  id=10   [slave
> pointer  (2)]
> ⎜   ↳ ETPS/2 Elantech Touchpad                  id=15   [slave
> pointer  (2)]
> ⎣ Virtual core keyboard                         id=3    [master
> keyboard (2)]
>      ↳ Virtual core XTEST keyboard               id=5    [slave
> keyboard (3)]
>      ↳ Power Button                              id=6    [slave  keyboard (3)]
>>
> We see the mouse id is 10, next look at the list of properties:
>
> $ xinput list-props 100
> Device 'PixArt USB Optical Mouse':
>          Device Enabled (140):   1
>          Coordinate Transformation Matrix (142): 1.000000, 0.000000,
> 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
>          Device Accel Profile (265):     0
>          Device Accel Constant Deceleration (266):       1.000000
>          Device Accel Adaptive Deceleration (267):       1.000000
>          Device Accel Velocity Scaling (268):    10.000000
>          Device Product ID (260):        2362, 9488
>          Device Node (261):      "/dev/input/event5"
>          Evdev Axis Inversion (269):     0, 0
>          Evdev Axes Swap (271):  0
>>
> Next set the first two «ones» of the property №142 to any other value
> and see does the pointer speed now good for us:
>
> $
> xinput set-prop 10 142 2.400000, 0.000000, 0.000000, 0.000000,
> 2.400000, 0.000000, 0.000000, 0.000000, 1.000000
>
> That's all!
>


More information about the xorg mailing list