struct Termbox::Event::KeyEvent
- Termbox::Event::KeyEvent
- Termbox::Event::BaseEvent
- Struct
- Value
- Object
Overview
Emitted by those key press events that are not representable by a printable(-ish) Char and a modifier.
Defined in:
termbox2/event.crConstructors
Class Method Summary
-
.from(event)
Creates a
KeyEvent
from a Termbox event struct.
Instance Method Summary
-
#char : Char | Nil
Returns the char that was pressed.
-
#key : Key | Nil
Returns the key that was pressed.
-
#mod : KeyModifier
Returns the key modifier.
Instance methods inherited from struct Termbox::Event::BaseEvent
initialize
initialize
Constructor methods inherited from struct Termbox::Event::BaseEvent
new
new
Class methods inherited from struct Termbox::Event::BaseEvent
from(event : LibTermbox::Event)
from
Constructor Detail
Class Method Detail
Instance Method Detail
def char : Char | Nil
#
Returns the char that was pressed. Either this or #key
is available for key events.
Returns the key that was pressed. Either this or #char
is available for key events.