pub enum ModifierKey {
LeftShift,
LeftControl,
LeftOption,
LeftCommand,
LeftExtra1,
LeftExtra2,
RightShift,
RightControl,
RightOption,
RightCommand,
RightExtra1,
RightExtra2,
}
Expand description
A physical modifier key.
This enumeration comprises physical keys instead of logical Modifier
s.
Variants§
LeftShift
LeftControl
LeftOption
LeftCommand
LeftExtra1
LeftExtra2
RightShift
RightControl
RightOption
RightCommand
RightExtra1
RightExtra2
Implementations§
Source§impl ModifierKey
impl ModifierKey
Sourcepub fn with_csi_u(code: u16) -> Option<Self>
pub fn with_csi_u(code: u16) -> Option<Self>
Map the CSI/u key code to a modifier key.
Sourcepub fn as_modifier(&self) -> Modifier
pub fn as_modifier(&self) -> Modifier
Convert this modifier key into a logical modifier flag.
Trait Implementations§
Source§impl Clone for ModifierKey
impl Clone for ModifierKey
Source§fn clone(&self) -> ModifierKey
fn clone(&self) -> ModifierKey
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for ModifierKey
impl Debug for ModifierKey
Source§impl Hash for ModifierKey
impl Hash for ModifierKey
Source§impl PartialEq for ModifierKey
impl PartialEq for ModifierKey
impl Copy for ModifierKey
impl Eq for ModifierKey
impl StructuralPartialEq for ModifierKey
Auto Trait Implementations§
impl Freeze for ModifierKey
impl RefUnwindSafe for ModifierKey
impl Send for ModifierKey
impl Sync for ModifierKey
impl Unpin for ModifierKey
impl UnwindSafe for ModifierKey
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