coastline 0.0.4
Loading...
Searching...
No Matches
coastline::WizardEvent Struct Reference

An event of the keyboard or the mouse. More...

#include <setupwizard.h>

Collaboration diagram for coastline::WizardEvent:

Public Types

enum class  Type {
  Key , Text , Accelerator , MouseDown ,
  MouseUp , MouseMove , Wheel
}
 The kind of event. More...

Public Attributes

Type type = Type::Key
WizardKey key = WizardKey::Tab
bool shift = false
std::string text
char letter = 0
int x = 0
int y = 0
int wheel = 0
std::uint64_t milliseconds = 0

Detailed Description

An event of the keyboard or the mouse.

Member Enumeration Documentation

◆ Type

enum class coastline::WizardEvent::Type
strong

The kind of event.

Enumerator
Key 

A press of key.

Text 

text typed or pasted.

Accelerator 

Alt and letter.

MouseDown 

The left button pressed at x and y.

MouseUp 

The left button released at x and y.

MouseMove 

The mouse moved to x and y.

Wheel 

The wheel turned wheel notches at x and y.

Member Data Documentation

◆ type

Type coastline::WizardEvent::type = Type::Key

The kind of event.

◆ key

WizardKey coastline::WizardEvent::key = WizardKey::Tab

The key of a Key event.

◆ shift

bool coastline::WizardEvent::shift = false

Whether Shift is pressed with the key.

◆ text

std::string coastline::WizardEvent::text

The UTF-8 text of a Text event.

◆ letter

char coastline::WizardEvent::letter = 0

The lowercase letter of an Accelerator event.

◆ x

int coastline::WizardEvent::x = 0

The mouse across the 640 by 400 grid, in pixels.

◆ y

int coastline::WizardEvent::y = 0

The mouse down the 640 by 400 grid, in pixels.

◆ wheel

int coastline::WizardEvent::wheel = 0

The notches of a Wheel event, above 0 away from the user.

◆ milliseconds

std::uint64_t coastline::WizardEvent::milliseconds = 0

The time of the event, for double-clicks and typing.


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