djpohly / dwl

dwm for Wayland - ARCHIVE: development has moved to Codeberg
https://codeberg.org/dwl/dwl
Other
1.93k stars 280 forks source link

Feature request: add graphics tablet support (wacom) patch #336

Open ghost opened 2 years ago

ghost commented 2 years ago

Hello hope you are doing well. I was wondering are there plans for adding wacom tablet support? I recall sway has this support and I would think it would be really nice if dwl had it as well. As art creators and even academics in general would love this feature as it will allow us to use software such as gimp, krita, blender, xournalpp etc with our tablet without relying on the inefficiencies of the mouse. Sure we could always use sway full time and not go into dwl, however I have a lot of nice patches on dwl especially the swallow patch which I can't live without so my only option would be to request this feature for dwl even as a patch it would be more than enough.

Kind regards,

Geronymos commented 1 year ago

Here is the implementation from sway https://github.com/swaywm/sway/pull/4570/files. I also would like this feature. I might have a look at it myself if I find time :)

Kuchteq commented 1 year ago

It would be great to have a patch like that! One of the two caveats I have that make me still start up dwm from time to time.

RibalGZ commented 1 year ago

Maybe just adding a new libinput rule available in config.h which works similar to the xinput map-to-output command, where you specify the libinput pen ID and the monitor ID.

nicolas3121 commented 1 year ago

would love to see this as well i'm quite dependant on xournalpp

d4r1us-drk commented 1 year ago

I also would love to see this implemented, I have a Thinkpad X1 Yoga Gen5 and it comes with a pen and the screen is a wacom touchscreen. I'm using the touchscreen patch, but this only emulates a mouse and the pen isn't working.

odrling commented 1 year ago

It would still be nice to have tablet support in dwl, but in the meantime I have to mention OpenTabletDriver. It seems not to support every tablet under the sun but it's been working fine for me.

Xgames123 commented 1 year ago

Here is the implementation from sway https://github.com/swaywm/sway/pull/4570/files. I also would like this feature. I might have a look at it myself if I find time :)

I'm currently trying to add this to dwl

Xgames123 commented 1 year ago

I'm currently a bit stuck.

Does anyone know why my drawing tablet isn't getting a new_input event call. It does show up when I do libinput list-devices Do I need to do something to notify libinput to send it to the compositor?

Here my code: https://github.com/Xgames123/dwl/blob/drawingtablet/dwl.c

RibalGZ commented 1 year ago

I'm currently a bit stuck.

Does anyone know why my drawing tablet isn't getting a new_input event call. It does show up when I do libinput list-devices Do I need to do something to notify libinput to send it to the compositor?

Here my code: https://github.com/Xgames123/dwl/blob/drawingtablet/dwl.c

In case it helps, there is this article about input handling in wlroots: https://drewdevault.com/2018/07/17/Input-handling-in-wlroots.html

Towards the end of the article he makes a comment regarding the drawing tablet events.

Xgames123 commented 1 year ago

I'm currently a bit stuck.

Does anyone know why my drawing tablet isn't getting a new_input event call. It does show up when I do libinput list-devices Do I need to do something to notify libinput to send it to the compositor?

Here my code: https://github.com/Xgames123/dwl/blob/drawingtablet/dwl.c

For some reason nothing gets a new_input call????? But the pointer and keyboard work?? The backend is multibackend with drm and libinput If I run on wayland backend all the events get send except for tablet (is probably because the host compositor doesn't support drawing tablets)