pub struct KeymapOutput { /* private fields */ }
Expand description
Constructs an HID report or a sequence of key codes from the given sequence of key::KeyOutput.
Implementations§
Source§impl KeymapOutput
impl KeymapOutput
Sourcepub fn new(pressed_key_codes: Vec<KeyOutput, { MAX_PRESSED_KEYS }>) -> Self
pub fn new(pressed_key_codes: Vec<KeyOutput, { MAX_PRESSED_KEYS }>) -> Self
Constructs a new keymap output.
Sourcepub fn pressed_key_codes(&self) -> Vec<u8, 24>
pub fn pressed_key_codes(&self) -> Vec<u8, 24>
Returns the pressed key codes.
Sourcepub fn as_hid_boot_keyboard_report(&self) -> [u8; 8]
pub fn as_hid_boot_keyboard_report(&self) -> [u8; 8]
Returns the current HID keyboard report.
Sourcepub fn pressed_custom_codes(&self) -> Vec<u8, 24>
pub fn pressed_custom_codes(&self) -> Vec<u8, 24>
Returns the pressed custom codes.
Trait Implementations§
Source§impl Debug for KeymapOutput
impl Debug for KeymapOutput
Source§impl Default for KeymapOutput
impl Default for KeymapOutput
Source§impl PartialEq for KeymapOutput
impl PartialEq for KeymapOutput
impl StructuralPartialEq for KeymapOutput
Auto Trait Implementations§
impl Freeze for KeymapOutput
impl RefUnwindSafe for KeymapOutput
impl Send for KeymapOutput
impl Sync for KeymapOutput
impl Unpin for KeymapOutput
impl UnwindSafe for KeymapOutput
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more