Enum sfml::window::Key [] [src]

pub enum Key {
    Unknown,
    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,
    Num0,
    Num1,
    Num2,
    Num3,
    Num4,
    Num5,
    Num6,
    Num7,
    Num8,
    Num9,
    Escape,
    LControl,
    LShift,
    LAlt,
    LSystem,
    RControl,
    RShift,
    RAlt,
    RSystem,
    Menu,
    LBracket,
    RBracket,
    SemiColon,
    Comma,
    Period,
    Quote,
    Slash,
    BackSlash,
    Tilde,
    Equal,
    Dash,
    Space,
    Return,
    BackSpace,
    Tab,
    PageUp,
    PageDown,
    End,
    Home,
    Insert,
    Delete,
    Add,
    Subtract,
    Multiply,
    Divide,
    Left,
    Right,
    Up,
    Down,
    Numpad0,
    Numpad1,
    Numpad2,
    Numpad3,
    Numpad4,
    Numpad5,
    Numpad6,
    Numpad7,
    Numpad8,
    Numpad9,
    F1,
    F2,
    F3,
    F4,
    F5,
    F6,
    F7,
    F8,
    F9,
    F10,
    F11,
    F12,
    F13,
    F14,
    F15,
    Pause,
    KeyCount,
}

Key codes known to SFML.

Variants

Unknown

An unhandled key.

ABCDEFGHIJKLMNOPQRSTUVWXYZNum0Num1Num2Num3Num4Num5Num6Num7Num8Num9EscapeLControlLShiftLAltLSystem

The left OS-specific key: Window, Apple, so on.

RControlRShiftRAltRSystem

The right OS-specific key: Window, Apple, so on.

MenuLBracketRBracketSemiColonCommaPeriodQuoteSlashBackSlashTildeEqualDashSpaceReturnBackSpaceTabPageUpPageDownEndHomeInsertDeleteAdd

The numpad addition key.

Subtract

The numpad subtraction key.

Multiply

The numpad multiplication key.

Divide

The numpad division key.

LeftRightUpDownNumpad0Numpad1Numpad2Numpad3Numpad4Numpad5Numpad6Numpad7Numpad8Numpad9F1F2F3F4F5F6F7F8F9F10F11F12F13F14F15PauseKeyCount

The maximum available key code (not a real key).

Methods

impl Key
[src]

fn is_pressed(self) -> bool

Return whether this key is currently pressed.

Queries the real-time state of the keyboard, even if keys have been pressed or released while no window was focused and no events were triggered.

Trait Implementations

impl Copy for Key
[src]

impl Debug for Key
[src]

fn fmt(&self, __arg_0: &mut Formatter) -> Result

Formats the value using the given formatter.

impl Ord for Key
[src]

fn cmp(&self, __arg_0: &Key) -> Ordering

This method returns an Ordering between self and other. Read more

impl PartialOrd for Key
[src]

fn partial_cmp(&self, __arg_0: &Key) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more

fn lt(&self, other: &Rhs) -> bool
1.0.0

This method tests less than (for self and other) and is used by the < operator. Read more

fn le(&self, other: &Rhs) -> bool
1.0.0

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more

fn gt(&self, other: &Rhs) -> bool
1.0.0

This method tests greater than (for self and other) and is used by the > operator. Read more

fn ge(&self, other: &Rhs) -> bool
1.0.0

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more

impl Eq for Key
[src]

impl PartialEq for Key
[src]

fn eq(&self, __arg_0: &Key) -> bool

This method tests for self and other values to be equal, and is used by ==. Read more

fn ne(&self, other: &Rhs) -> bool
1.0.0

This method tests for !=.

impl Clone for Key
[src]

fn clone(&self) -> Key

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)
1.0.0

Performs copy-assignment from source. Read more