CeresEngine 0.2.0
A game development framework
Loading...
Searching...
No Matches
CeresEngine::KeyEvent Struct Referencefinal

A structure that describes a key press event. More...

#include <CeresEngine/Input/InputEvent.hpp>

Inheritance diagram for CeresEngine::KeyEvent:
CeresEngine::InputEvent

Public Attributes

KeyEventType type
 The type of key event represented by the event structure.
 
Button button = Button::None
 The button that has triggered the event.
 
ModifierButton modifiers
 The set of modifier keys pressed alongside this button.
 
bool isRepeat = false
 If set, indicates that the key is a repeat of a previous press.
 
UInt32 repeatCount = 0
 Defines the number of times the key press is repeating.
 
UInt32 scanCode = 0
 The system-specific scancode of the key.
 
- Public Attributes inherited from CeresEngine::InputEvent
double timestamp = 0.0
 The time when the event occurred in seconds since system startup.
 
PlatformWindowwindow = nullptr
 The platform window that triggered the input event, if any.
 

Static Public Attributes

static constexpr InputEventType structType = InputEventType::Key
 A value that determines the type of event represented by this event struct.
 

Detailed Description

A structure that describes a key press event.

Member Data Documentation

◆ button

Button CeresEngine::KeyEvent::button = Button::None

The button that has triggered the event.

◆ isRepeat

bool CeresEngine::KeyEvent::isRepeat = false

If set, indicates that the key is a repeat of a previous press.

◆ modifiers

ModifierButton CeresEngine::KeyEvent::modifiers

The set of modifier keys pressed alongside this button.

◆ repeatCount

UInt32 CeresEngine::KeyEvent::repeatCount = 0

Defines the number of times the key press is repeating.

◆ scanCode

UInt32 CeresEngine::KeyEvent::scanCode = 0

The system-specific scancode of the key.

◆ structType

constexpr InputEventType CeresEngine::KeyEvent::structType = InputEventType::Key
inlinestaticconstexpr

A value that determines the type of event represented by this event struct.

◆ type

KeyEventType CeresEngine::KeyEvent::type

The type of key event represented by the event structure.


The documentation for this struct was generated from the following file: