Add kwin-libei backend - #9
Conversation
KWin provides a libEI dbus interface, which requires no setup. Using it as the default input backend on KDE Plasma.
There was a problem hiding this comment.
Pull request overview
Adds a new KDE Plasma default input backend that injects input via KWin’s EIS D-Bus interface using libei, with fallback to the existing uinput backend elsewhere.
Changes:
- Introduces a new
KWinLibeiBackendand low-levelEISClient(libei + KWin EIS D-Bus). - Updates backend selection to prefer KWin/libei on KDE Plasma and adds backend shutdown on quit.
- Updates build/install and README dependency documentation to include the new module and D-Bus Python bindings.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 8 comments.
Show a summary per file
| File | Description |
|---|---|
| vboard/window.py | Selects KWin/libei backend on KDE; calls backend.close() on quit. |
| vboard/libei.py | New libei + KWin EIS D-Bus client implementation. |
| vboard/input_backends.py | Adds KWinLibeiBackend; refactors key map to a module constant; adds close() hook. |
| meson.build | Installs the new vboard/libei.py module. |
| README.md | Documents extra dependency (python3-dbus) and notes uinput requirements by desktop. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Thanks for the PR. How do I test this? What is the use case? |
|
It should work in KDE without needing to set up uinput. It talks to kwin via a private dbus interface. |
|
Sorry, again, about the delay. Does this give any additional improvement over the uinput backend? I don't want to make the app overcomplicated unless it really helps a lot. |
|
No. The only advantage is not having to setup uinput access. And it's totally fine if you don't want this. Most work is done by the kwin-mcp project. I just did a little bridging work. |
KWin provides a libEI dbus interface, which requires no setup. Using it as the default input backend on KDE Plasma.
libEI wrapper code is from https://github.com/isac322/kwin-mcp