#[repr(u32)]pub enum KeyCode {
Show 89 variants
A = 0,
B = 1,
C = 2,
D = 3,
E = 4,
F = 5,
G = 6,
H = 7,
I = 8,
J = 9,
K = 10,
L = 11,
M = 12,
N = 13,
O = 14,
P = 15,
Q = 16,
R = 17,
S = 18,
T = 19,
U = 20,
V = 21,
W = 22,
X = 23,
Y = 24,
Z = 25,
Key1 = 26,
Key2 = 27,
Key3 = 28,
Key4 = 29,
Key5 = 30,
Key6 = 31,
Key7 = 32,
Key8 = 33,
Key9 = 34,
Key0 = 35,
F1 = 36,
F2 = 37,
F3 = 38,
F4 = 39,
F5 = 40,
F6 = 41,
F7 = 42,
F8 = 43,
F9 = 44,
F10 = 45,
F11 = 46,
F12 = 47,
Space = 48,
Enter = 49,
Escape = 50,
Tab = 51,
Backspace = 52,
Delete = 53,
Insert = 54,
Home = 55,
End = 56,
PageUp = 57,
PageDown = 58,
Up = 59,
Down = 60,
Left = 61,
Right = 62,
LeftShift = 63,
RightShift = 64,
LeftCtrl = 65,
RightCtrl = 66,
LeftAlt = 67,
RightAlt = 68,
LeftSuper = 69,
RightSuper = 70,
Semicolon = 71,
Comma = 72,
Period = 73,
Slash = 74,
Backslash = 75,
LeftBracket = 76,
RightBracket = 77,
Equals = 78,
Minus = 79,
Apostrophe = 80,
Backquote = 81,
CapsLock = 82,
ScrollLock = 83,
NumLock = 84,
PrintScreen = 85,
Pause = 86,
ContextMenu = 87,
Unknown = 88,
}Expand description
Physical keyboard key.
Covers the common keyboard layout. For full coverage, use KeyCode from the
underlying windowing layer.
Variants§
A = 0
B = 1
C = 2
D = 3
E = 4
F = 5
G = 6
H = 7
I = 8
J = 9
K = 10
L = 11
M = 12
N = 13
O = 14
P = 15
Q = 16
R = 17
S = 18
T = 19
U = 20
V = 21
W = 22
X = 23
Y = 24
Z = 25
Key1 = 26
Key2 = 27
Key3 = 28
Key4 = 29
Key5 = 30
Key6 = 31
Key7 = 32
Key8 = 33
Key9 = 34
Key0 = 35
F1 = 36
F2 = 37
F3 = 38
F4 = 39
F5 = 40
F6 = 41
F7 = 42
F8 = 43
F9 = 44
F10 = 45
F11 = 46
F12 = 47
Space = 48
Enter = 49
Escape = 50
Tab = 51
Backspace = 52
Delete = 53
Insert = 54
Home = 55
End = 56
PageUp = 57
PageDown = 58
Up = 59
Down = 60
Left = 61
Right = 62
LeftShift = 63
RightShift = 64
LeftCtrl = 65
RightCtrl = 66
LeftAlt = 67
RightAlt = 68
LeftSuper = 69
RightSuper = 70
Semicolon = 71
Comma = 72
Period = 73
Slash = 74
Backslash = 75
LeftBracket = 76
RightBracket = 77
Equals = 78
Minus = 79
Apostrophe = 80
Backquote = 81
CapsLock = 82
ScrollLock = 83
NumLock = 84
PrintScreen = 85
Pause = 86
ContextMenu = 87
Unknown = 88
Unknown / unmapped key.
Trait Implementations§
impl Copy for KeyCode
impl Eq for KeyCode
impl StructuralPartialEq for KeyCode
Auto Trait Implementations§
impl Freeze for KeyCode
impl RefUnwindSafe for KeyCode
impl Send for KeyCode
impl Sync for KeyCode
impl Unpin for KeyCode
impl UnsafeUnpin for KeyCode
impl UnwindSafe for KeyCode
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