Expand description
§Keybind
Wrapper around device_query providing a nicer API, allowing you to trigger your logic on specific keybind.
§Example
ⓘ
use keybind::{Keybind, Keycode};
fn main() {
let mut keybind = Keybind::new(&[Keycode::LControl, Keycode::G]);
keybind.on_trigger(|| {
println!("This will be printed when you press CTRL+G");
});
keybind.wait();
}
Structs§
Enums§
- Keycode
- A list of supported keys that we can query from the OS. Outside of mod keys, we only support English keys at the moment.