pub enum Key {
}
Expand description
Type representing a keypress.
Variants§
String(String)
Char(char)
Bytes(Vec<u8>)
Byte(u8)
Ctrl(u8)
The associated value will be a byte corresponding to the lowercase
letter for the control code. For instance, ^A
will be Ctrl(b'a')
.
Meta(u8)
Backspace
Escape
Up
Down
Right
Left
KeypadUp
KeypadDown
KeypadRight
KeypadLeft
Home
End
Insert
Delete
PageUp
PageDown
F(u8)
The associated value will be the number corresponding to the F
key.
For instance, F1
will be F(1)
.
Implementations§
Trait Implementations§
impl Eq for Key
impl StructuralPartialEq for Key
Auto Trait Implementations§
impl Freeze for Key
impl RefUnwindSafe for Key
impl Send for Key
impl Sync for Key
impl Unpin for Key
impl UnwindSafe for Key
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