pub trait KeyboardKeyEvent<B: InputBackend>: Event<B> {
// Required methods
fn key_code(&self) -> Keycode;
fn state(&self) -> KeyState;
fn count(&self) -> u32;
}Expand description
Trait for keyboard event
Required Methods§
Sourcefn key_code(&self) -> Keycode
fn key_code(&self) -> Keycode
Returns the numerical button code of the keyboard button.
The value will correspond to one KEY_ constants from the Linux input event codes inside
input-event-codes.h.
Implementations on Foreign Types§
Source§impl KeyboardKeyEvent<LibinputInputBackend> for KeyboardKeyEvent
Available on crate feature backend_libinput only.
impl KeyboardKeyEvent<LibinputInputBackend> for KeyboardKeyEvent
Available on crate feature
backend_libinput only.Implementors§
impl KeyboardKeyEvent<WinitInput> for WinitKeyboardInputEvent
Available on crate feature
backend_winit only.impl KeyboardKeyEvent<X11Input> for X11KeyboardInputEvent
Available on crate feature
backend_x11 only.