Changing x&y valuator min-max values when rotating screen

Magnus Vigerlöf Magnus.Vigerlof at home.se
Tue Feb 5 12:35:27 PST 2008


Hello,

As I understand after looking at how gimp behaves (Xournal seems to behave in 
the same way) the min and max values of the x&y valuators of an opened 
extended InputDevice are cached somewhere in the application.

I understand that we probably shouldn't change these values after the first 
call to InitValuatorAxisStruct for each axis. But then we have a problem if 
we have a tablet-PC with a screen can be rotated. If the screen have been 
rotated we have to rotate the values reported on the x&y axis as well, and 
with that the min/max values as perceived from the clients.

Restarting the applications that uses the extended input information when this 
happeneds works, but is hardly an elegant way to solve it.

WIth xserver 1.4 and the possibility to hotplug InputDevices, re-registering 
the devices should work as well, but I don't think this is elegant either.

Are there other ways to ensure that the applications become aware that 
properties have changed on the input devices that could be used? Can the event 
that signals that InputDevices has been added removed be used in some way?

Cheers
  Magnus



More information about the xorg mailing list