[−][src]Enum keytokey::KeyCode
usb key codes mapped into the first private region of unicode USBKeyOut must substract UNICODE_BELOW_256 to create valid u8 values to transmit
Variants
No
ErrorRollOver
PostFail
ErrorUndefined
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
Kb1
Kb2
Kb3
Kb4
Kb5
Kb6
Kb7
Kb8
Kb9
Kb0
Enter
Escape
BSpace
Tab
Space
Minus
Equal
LBracket
RBracket
BSlash
NonUsHash
SColon
Quote
Grave
Comma
Dot
Slash
CapsLock
F1
F2
F3
F4
F5
F6
F7
F8
F9
F10
F11
F12
PScreen
ScrollLock
Pause
Insert
Home
PgUp
Delete
End
PgDown
Right
Left
Down
Up
NumLock
KpSlash
KpAsterisk
KpMinus
KpPlus
KpEnter
Kp1
Kp2
Kp3
Kp4
Kp5
Kp6
Kp7
Kp8
Kp9
Kp0
KpDot
NonUsBslash
Application
LCtrl
LShift
LAlt
LGui
RCtrl
RShift
RAlt
RGui
Methods
impl KeyCode
[src]
pub fn is_modifier(self) -> bool
[src]
needed to build USB reports
pub fn as_modifier_bit(self) -> u8
[src]
needed to build USB reports
pub fn to_u8(self) -> u8
[src]
Trait Implementations
impl AcceptsKeycode for KeyCode
[src]
impl Debug for KeyCode
[src]
impl PartialEq<KeyCode> for KeyCode
[src]
fn eq(&self, other: &KeyCode) -> bool
[src]
#[must_use]
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.
impl Eq for KeyCode
[src]
impl Ord for KeyCode
[src]
fn cmp(&self, other: &KeyCode) -> Ordering
[src]
fn max(self, other: Self) -> Self
1.21.0[src]
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.21.0[src]
Compares and returns the minimum of two values. Read more
fn clamp(self, min: Self, max: Self) -> Self
[src]
clamp
)Restrict a value to a certain interval. Read more
impl PartialOrd<KeyCode> for KeyCode
[src]
fn partial_cmp(&self, other: &KeyCode) -> Option<Ordering>
[src]
#[must_use]
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests less than (for self
and other
) and is used by the <
operator. Read more
#[must_use]
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
#[must_use]
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
#[must_use]
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl Copy for KeyCode
[src]
impl TryFrom<u32> for KeyCode
[src]
type Error = String
The type returned in the event of a conversion error.
fn try_from(number: u32) -> Result<Self, String>
[src]
impl TryFrom<u8> for KeyCode
[src]
type Error = String
The type returned in the event of a conversion error.
fn try_from(ii: u8) -> Result<KeyCode, Self::Error>
[src]
impl From<KeyCode> for u32
[src]
impl Clone for KeyCode
[src]
Auto Trait Implementations
impl Unpin for KeyCode
impl Sync for KeyCode
impl Send for KeyCode
impl RefUnwindSafe for KeyCode
impl UnwindSafe for KeyCode
Blanket Implementations
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,