rdev
rdev copied to clipboard
Use libinput to monitor for events on Linux
This will provide compatibility for Wayland and X11, as X11 uses Libinput under the hood now for its event source.
There are several linux keyboard macro systems now that use libinput for example.
I’d be willing to contribute to rdev to add this. Any advice about that before I dive in? My understanding is that the key file to update is listen.rs
I've got a sample app using libinput that gets key code events and (some) mouse information, here, that may be of use. Problems I'm encountering currently:
- Key codes do not match with what rdev has defined
- EX libinput key event
ais30=> rdev is38 - libinput
bis 48 => rdev is56 - libinput
cis 46 => rdev is54
- EX libinput key event
- Pointer motion events (for a mouse) are limited to relative XY changes
- Getting initial absolute position seems to be non-trivial since wayland doesn't allow querying the mouse outside of the windows owned by the application
我已收到你发的邮件,谢谢