#[repr(u8)]pub enum Key {
Show 110 variants
CapsLock = 0,
Shift = 1,
Control = 2,
Alt = 3,
Meta = 4,
ControlOrMeta = 5,
RightShift = 6,
RightControl = 7,
RightAlt = 8,
RightMeta = 9,
RightControlOrMeta = 10,
Fn = 11,
ReturnOrEnter = 12,
Escape = 13,
DeleteOrBackspace = 14,
ForwardDelete = 15,
Insert = 16,
Tab = 17,
Space = 18,
Minus = 19,
Equal = 20,
LeftBracket = 21,
RightBracket = 22,
Backslash = 23,
Semicolon = 24,
Quote = 25,
Grave = 26,
Comma = 27,
Period = 28,
Slash = 29,
UpArrow = 30,
RightArrow = 31,
DownArrow = 32,
LeftArrow = 33,
PageUp = 34,
PageDown = 35,
Home = 36,
End = 37,
A = 38,
B = 39,
C = 40,
D = 41,
E = 42,
F = 43,
G = 44,
H = 45,
I = 46,
J = 47,
K = 48,
L = 49,
M = 50,
N = 51,
O = 52,
P = 53,
Q = 54,
R = 55,
S = 56,
T = 57,
U = 58,
V = 59,
W = 60,
X = 61,
Y = 62,
Z = 63,
N0 = 64,
N1 = 65,
N2 = 66,
N3 = 67,
N4 = 68,
N5 = 69,
N6 = 70,
N7 = 71,
N8 = 72,
N9 = 73,
Numpad0 = 74,
Numpad1 = 75,
Numpad2 = 76,
Numpad3 = 77,
Numpad4 = 78,
Numpad5 = 79,
Numpad6 = 80,
Numpad7 = 81,
Numpad8 = 82,
Numpad9 = 83,
NumpadClear = 84,
NumpadEquals = 85,
NumpadDivide = 86,
NumpadMultiply = 87,
NumpadMinus = 88,
NumpadPlus = 89,
NumpadEnter = 90,
NumpadDecimal = 91,
F1 = 92,
F2 = 93,
F3 = 94,
F4 = 95,
F5 = 96,
F6 = 97,
F7 = 98,
F8 = 99,
F9 = 100,
F10 = 101,
F11 = 102,
F12 = 103,
FastForward = 104,
Rewind = 105,
PlayPause = 106,
VolumeUp = 107,
VolumeDown = 108,
Mute = 109,
}
Expand description
A keyboard key used by the KeyboardContext
trait.
This implements the Enum
trait.
Variants§
CapsLock = 0
Shift = 1
Control = 2
Alt = 3
Meta = 4
ControlOrMeta = 5
RightShift = 6
RightControl = 7
RightAlt = 8
RightMeta = 9
RightControlOrMeta = 10
Fn = 11
ReturnOrEnter = 12
Escape = 13
DeleteOrBackspace = 14
ForwardDelete = 15
Insert = 16
Tab = 17
Space = 18
Minus = 19
Equal = 20
LeftBracket = 21
RightBracket = 22
Backslash = 23
Semicolon = 24
Quote = 25
Grave = 26
Comma = 27
Period = 28
Slash = 29
UpArrow = 30
RightArrow = 31
DownArrow = 32
LeftArrow = 33
PageUp = 34
PageDown = 35
Home = 36
End = 37
A = 38
B = 39
C = 40
D = 41
E = 42
F = 43
G = 44
H = 45
I = 46
J = 47
K = 48
L = 49
M = 50
N = 51
O = 52
P = 53
Q = 54
R = 55
S = 56
T = 57
U = 58
V = 59
W = 60
X = 61
Y = 62
Z = 63
N0 = 64
N1 = 65
N2 = 66
N3 = 67
N4 = 68
N5 = 69
N6 = 70
N7 = 71
N8 = 72
N9 = 73
Numpad0 = 74
Numpad1 = 75
Numpad2 = 76
Numpad3 = 77
Numpad4 = 78
Numpad5 = 79
Numpad6 = 80
Numpad7 = 81
Numpad8 = 82
Numpad9 = 83
NumpadClear = 84
NumpadEquals = 85
NumpadDivide = 86
NumpadMultiply = 87
NumpadMinus = 88
NumpadPlus = 89
NumpadEnter = 90
NumpadDecimal = 91
F1 = 92
F2 = 93
F3 = 94
F4 = 95
F5 = 96
F6 = 97
F7 = 98
F8 = 99
F9 = 100
F10 = 101
F11 = 102
F12 = 103
FastForward = 104
Rewind = 105
PlayPause = 106
VolumeUp = 107
VolumeDown = 108
Mute = 109
Trait Implementations§
source§impl Enum for Key
impl Enum for Key
source§fn display_name(&self) -> &'static str
fn display_name(&self) -> &'static str
The display name of this enum variant. Read more
source§fn identifier_name(&self) -> &'static str
fn identifier_name(&self) -> &'static str
The identifier name of this enum variant. Read more
source§fn iter() -> EnumIterator<Self> ⓘ
fn iter() -> EnumIterator<Self> ⓘ
Get an iterator over the variants of the enum.
impl Copy for Key
impl Eq for Key
impl StructuralEq for Key
impl StructuralPartialEq for Key
Auto Trait Implementations§
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