linuxwacom / libwacom

libwacom is a tablet description library
Other
330 stars 166 forks source link

Support non-mangled Wacom tool IDs #767

Open jigpu opened 2 weeks ago

jigpu commented 2 weeks ago

The Linux kernel maintainers are open to the idea of eventually removing tool ID mangling. Before we do this, we need to add the non-mangled versions of these IDs into libwacom so that applications can continue to work properly.

For reference, here is a complete list of all the affected pens / IDs. This list was made by finding all IDs in libwacom.stylus with the 4th nybble set to ‘0'. Versions of these IDs with the following nybbles right-shifted need to be added (e.g. mangled "0x10002" should have an un-mangled "0x1002" copy).

[0x10002] / [0x1000a]    # UD Pen (udpen)
[0x20802]                # Inking Pen
[0x40802] / [0x4080a]    # Classic Pen
[0x80842]                # Pro Pen 3D (mobilestudio)
[0x100802] / [0x10080a]  # Grip Pen (propengen2)
[0x100804] / [0x10080c]  # Art Pen (propengen2)
[0x100842] / [0x10084a]  # Pro Pen Slim (mobilestudio)
[0x100902] / [0x10090a]  # Airbrush Pen (propengen2)
[0x120802]               # Inking Pen (intuos5)
[0x140802] / [0x14080a]  # Classic Pen (propengen2)
[0x160802] / [0x16080a]  # Pro Pen (propengen2)
[0x180802] / [0x18080a]  # "Pen" (dth2242)

I can submit a patch that adds the non-mangled IDs easily enough, but I wonder if I should wait for #761 to be resolved first?

Also, is there a preference for having both mangled and non-mangled IDs exist in the same "libwacom.stylus" file, or would we want to move one of the two sets into a new stylus definition file?

whot commented 2 weeks ago

761 should be easy enough to implement, let's do this first please. I don't think we need a new .stylus file for 12 ids.