hollyhock
Loading...
Searching...
No Matches
GUIDialog Class Reference
Inheritance diagram for GUIDialog:
Collaboration diagram for GUIDialog:

Public Types

enum  Height : int {
  Height25 = 0 , Height55 = 1 , Height75 = 2 , Height95 = 3 ,
  Height35 = 4 , Height60 = 5
}
enum  Alignment : int { AlignTop = 0 , AlignCenter = 1 , AlignBottom = 2 }
enum  KeyboardState : int {
  KeyboardStateNone = 0 , KeyboardStateMath1 = 1 , KeyboardStateMath2 = 4 , KeyboardStateMath3 = 5 ,
  KeyboardStateTrig = 6 , KeyboardStateVar = 7 , KeyboardStateABC = 8 , KeyboardStateCatalog = 9 ,
  KeyboardStateAdvance = 10 , KeyboardStateNumber = 11
}
enum  DialogResult : int { DialogResultOK = 0x3EA , DialogResultCancel = 0x3EB }

Public Member Functions

 GUIDialog (enum Height height, enum Alignment alignment, const char *title, enum KeyboardState keyboard)
virtual int OnEvent (struct GUIDialog_Wrapped *dialog, struct GUIDialog_OnEvent_Data *event)
uint16_t GetLeftX ()
uint16_t GetTopY ()
uint16_t GetRightX ()
uint16_t GetBottomY ()
void AddElement (GUIElement &element)
void Refresh ()
DialogResult ShowDialog ()
Public Member Functions inherited from Wrapped
template<typename T>
T * GetWrapped ()

Additional Inherited Members

Protected Member Functions inherited from Wrapped
 Wrapped (Wrapped const &)=delete
void operator= (Wrapped const &)=delete
Protected Attributes inherited from Wrapped
void * m_wrapped
 A pointer to the wrapped class.

Constructor & Destructor Documentation

◆ GUIDialog()

GUIDialog::GUIDialog ( enum Height height,
enum Alignment alignment,
const char * title,
enum KeyboardState keyboard )

Creates a dialog.

Parameters
heightThe height of the dialog.
alignmentThe screen position to align the dialog with.
[in]titleThe string to display in the title bar of the dialog.
keyboardThe keyboard to display when the dialog is shown.

Member Function Documentation

◆ AddElement()

void GUIDialog::AddElement ( GUIElement & element)

Adds a GUI element to the dialog.

Parameters
elementThe GUI element to add.

◆ GetBottomY()

uint16_t GUIDialog::GetBottomY ( )

Returns the Y position of the bottom edge of the dialog body, in pixels.

Returns
The Y position of the bottom edge of the dialog body, in pixels.

◆ GetLeftX()

uint16_t GUIDialog::GetLeftX ( )

Returns the X position of the left edge of the dialog body, in pixels.

Returns
The X position of the left edge of the dialog body, in pixels.

◆ GetRightX()

uint16_t GUIDialog::GetRightX ( )

Returns the X position of the right edge of the dialog body, in pixels.

Returns
The X position of the right edge of the dialog body, in pixels.

◆ GetTopY()

uint16_t GUIDialog::GetTopY ( )

Returns the Y position of the top edge of the dialog body, in pixels.

Returns
The Y position of the top edge of the dialog body, in pixels.

◆ Refresh()

void GUIDialog::Refresh ( )

Refreshes the dialog, redrawing all components.

◆ ShowDialog()

GUIDialog::DialogResult GUIDialog::ShowDialog ( )

Presents the dialog to the user. Blocks until the dialog is closed.

Returns
The result of the dialog.

The documentation for this class was generated from the following files: