Wacomtablet moved to kdereview
Jörg Ehrichs
Joerg.Ehrichs at gmx.de
Tue Oct 5 20:42:00 BST 2010
Am Montag, 4. Oktober 2010, 22:02:11 schrieb Fredrik Höglund:
> On Thursday 30 September 2010, Jörg Ehrichs wrote:
> > Am Donnerstag, 30. September 2010, 07:52:01 schrieb Gökçen Eraslan:
> > > By the way, do you think to use xinput libraries instead of parsing
> > > xinput and xsetwacom commands? Output structure of commands may change
> > > in future. Maybe you can add a TODO file to project about this.
> >
> > Yes i thought about it. Shortly after i wrote the parsing code i do know.
> > The only reason why I still use the big list of parsing rules just to get
> > the vendor and Tablet / input device names is, that I couldn't get it to
> > work with libsolid for any usecase. So I decided in the first step I'm
> > actually happy that this way is working and as soon the basics work for
> > everyone, I#ll go and dig deeper into how I could solve the tablet
> > detection / hotplugging via solid and change all of it afterwards.
>
>
> Relying on XInput instead of Solid should also simplify your code a lot,
> since you don't have to map the device names you get from Solid to the
> names assigned to the devices by the X server. You only have one
> interface and one device ID. It also looks to me like this mapping code
> has a good chance of picking the wrong device when there is more than
> one tablet connected to the computer.
Changing from the rather buggy old parsing code to direct XInput calls reduced
the whole device detection already a lot and hopefully makes it less error
prone.
> There is also another aspect you should consider when you use Solid to
> detect input and output devices, and that's that when you're dealing
> with a remote X connection, the machine KDE is running on is not the
> machine those devices are connected to.
This is something I've never thought about, but it does make a lot of sense.
Also explains why there is no support for input devices in solid up to now as
this is not the right place to add it.
Apart from device detection (which should hopefully be solved by native X11
calls directly now), I used Solid to get notified when a new tablet was plugged
in / removed from the system.
> I just want to point out that if you use XInput, you don't need Solid,
> because the X server dispatches events to applications when devices
> are connected and disconnected.
I assume this means I could "easily" switch from the current device HotPlug
detection to something X11 offers already? I've tried to find something on
freedesktop.org and with Google, but could get anything useful in this
direction.
Could you give me a small hint, where to look to get this implemented?
Kind Regards
Jörg
More information about the kde-core-devel
mailing list