keybind 0.1.0

Trigger logic on specific keybind.
Documentation
  • Coverage
  • 71.43%
    5 out of 7 items documented0 out of 5 items with examples
  • Size
  • Source code size: 7.2 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 1.51 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Links
  • rustysoft/keybind
    3 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • kunicmarko20

Keybind

Wrapper around device_query providing a nicer API, allowing you to trigger your logic on specific keybind.

Full Documentation can be read here.

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();
}