Keyboard event capture in linux (wayland/KDE)
ā Rust š 2025-12-18 š¤ surdeus šļø 6I. Problem (what I hope to achieve):
- timed key events (ex. rapid Space fires machine-gun, slower Space fires cannon)
- total keyboard capture (ex. Meta brings up MyGameOptions instead of Desktop Environment launcher like it does system wide)
- KeyPress and KeyRelease events (ex. modiffiers A_KeyPress && B_KeyPress && SpaceKeyRelease => FireDeathStar )
II. Background (what I kindda understood so far):
- I'm at hello word level so... be gentle.
- Iām on linux, wayland, KDE ā not interested on other platforms for now
- crossterm and termion are close but not there all the way for my use case - pls correct me if I'm wrong
- Games can do it full screen, Qemu can do it in a window, so I should be able to do it in a terminal emulator window also, right?
- Iām not doing a game (the examples are just that, examples) so struggling to understand a game engine library would be too much for me
- Thanks in advance to anyone helping but pls be aware: any response will be followed by more, even dumber questions

1 post - 1 participant
š·ļø Rust_feed