Class KeyTypeEvent#

Inheritance Relationships#

Base Type#

Class Documentation#

class KeyTypeEvent : public TRAP::Events::Event#

Key typed.

Remark

Headless mode: This class is not available in headless mode.

Public Functions

explicit KeyTypeEvent(u32 codePoint, TRAP::Window &window)#

Constructor.

Note

The window must outlive the KeyTypeEvent!

Parameters:
  • codePoint – Unicode code point entered.

  • window – The affected window.

constexpr ~KeyTypeEvent() override = default#

Destructor.

consteval KeyTypeEvent(const KeyTypeEvent&) noexcept = delete#

Copy constructor.

consteval KeyTypeEvent &operator=(const KeyTypeEvent&) noexcept = delete#

Copy assignment operator.

constexpr KeyTypeEvent(KeyTypeEvent&&) noexcept = default#

Move constructor.

KeyTypeEvent &operator=(KeyTypeEvent&&) noexcept = default#

Move assignment operator.

constexpr TRAP::Window &GetWindow() const noexcept#

Retrieve a reference to the affected window.

Returns:

Window reference.

constexpr u32 GetCodePoint() const noexcept#

Retrieve the entered Unicode code point.

Returns:

Unicode code point.

virtual constexpr EventType GetEventType() const noexcept override#

Retrieve the EventType of the event.

Returns:

EventType.

virtual constexpr std::string GetName() const override#

Retrieve the name of the event.

Returns:

Name.

virtual constexpr EventCategory GetCategoryFlags() const noexcept override#

Retrieve the category flags of the event.

Returns:

Combination of one or more EventCategory’s.

virtual std::string ToString() const override#

Get a string representation of the event.

Returns:

String representation.

Public Static Functions

static constexpr EventType GetStaticType() noexcept#

Retrieve the EventType of the event.

Returns:

EventType.