pub enum KeyAction {
Inherit,
Normal(KeyCode),
Normal2(KeyCode, KeyCode),
TapHold(KeyCode, KeyCode),
OneShot(KeyCode),
TapDance(u8),
}
Expand description
Represents key action.
Variants§
Inherit
Inherit key definition from parent layer.
Normal(KeyCode)
Normal key
Normal2(KeyCode, KeyCode)
Normal key with secondary key. These keys are sent together.
TapHold(KeyCode, KeyCode)
Tap-Hold key (tap, hold)
If key is pressed and released in KeyResolverConfig::tap_hold
, tap key is sent.
If key is pressed and held longer, hold key is sent. Also, rktk-keymanager
emulates qmk’s HOLD_ON_OTHER_KEY_PRESS
feature.
If another key is pressed while holding this key, even before tap_threshold
, hold key is sent.
OneShot(KeyCode)
One-shot key
After pressing this key, the key will be sent together with the next key press.
TapDance(u8)
Tap-dance (id)
Execute tap-dance with specified id. TapDance can be configured in KeyResolverConfig
.
Implementations§
Source§impl KeyAction
impl KeyAction
pub const fn const_default() -> Self
Trait Implementations§
impl Copy for KeyAction
impl Eq for KeyAction
impl StructuralPartialEq for KeyAction
Auto Trait Implementations§
impl Freeze for KeyAction
impl RefUnwindSafe for KeyAction
impl Send for KeyAction
impl Sync for KeyAction
impl Unpin for KeyAction
impl UnwindSafe for KeyAction
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