Vivoe Lite 0.5.0
Lightweight GVA like HMI for military displays.
Loading...
Searching...
No Matches
gva::WidgetMessageBox Class Reference

Class defining the mode widget. More...

#include <message_box.h>

Inheritance diagram for gva::WidgetMessageBox:
Inheritance graph
Collaboration diagram for gva::WidgetMessageBox:
Collaboration graph

Public Member Functions

 WidgetMessageBox (const RendererGva &renderer, TouchGva *touch)
 Construct a new Widget Keyboard object.
 
 ~WidgetMessageBox () final=default
 Destroy the Widget mode object.
 
std::string GetWidgetName () const final
 Get the Widget Name attribute.
 
void Draw () final
 Draw the current widget.
 
void SetMessage (const std::string_view message_text, widget::IconType icon)
 Set the Message text and icon.
 
- Public Member Functions inherited from gva::WidgetTable
 WidgetTable (const RendererGva &renderer, TouchGva *touch, uint32_t background_colour=0x000000)
 Construct a new Widget Table object.
 
 ~WidgetTable () override=default
 Destroy the Widget Keyboard object.
 
std::string GetWidgetName () const override
 Get the Widget Name attribute.
 
void Draw () override
 The base class override to draw the table once setup.
 
virtual void AddRow (uint32_t foreground_colour, uint32_t background_colour, uint32_t outline_colour, uint32_t highlight_colour, widget::WeightType font_weight)
 Add a row to the table.
 
virtual void AddRow ()
 Add a row to the table.
 
virtual void AddRow (widget::WeightType font_weight)
 Add a row to the table.
 
virtual void AddCell (const std::string text, uint32_t width)
 Add a basic cell.
 
virtual void AddCell (const std::string text, uint32_t width, uint32_t background_colour)
 Add a new cell with background colour.
 
virtual void AddCell (const std::string text, uint32_t width, widget::CellAlignType align)
 Add a new cell specifying alignment.
 
virtual void AddCell (const std::string text, uint32_t width, widget::CellAlignType align, uint32_t background_colour)
 Add a new cell specifying alignment.
 
void Reset ()
 Reset the table.
 
uint32_t GetBackgroundColour () const
 Get the Background Colour attribute.
 
void SetBackgroundColour (uint32_t background_colour)
 Set the Background Colour attribute.
 
void SetCurrentRow (uint32_t row)
 Set the Current selected row, will be highlighted in the theme colours.
 
void SetNextRow ()
 Set the Next Row attribute.
 
void SetPreviousRow ()
 Set the Previous Row attribute.
 
uint32_t GetCurrentRow () const
 Get the Current selected highlighted row.
 
std::vector< RowType > & GetRows ()
 Get the Rows vector.
 
void SetRows (const std::vector< RowType > &rows)
 Get the all the Rows in supplie vector.
 
- Public Member Functions inherited from gva::WidgetX
 WidgetX (const RendererGva &renderer, widget::WidgetEnum widget_type)
 Construct a new Widget X object.
 
virtual widget::WidgetEnum GetWidgetType () const
 Get the Widget Type attribute.
 
void SetVisible (bool visible)
 Set the Visible object.
 
bool GetVisible () const
 Get the Visible object.
 
virtual void SetX (uint32_t x)
 Set the X dimension.
 
uint32_t GetX () const
 Get the Y dimension.
 
virtual void SetY (uint32_t y)
 Set the Y dimension.
 
uint32_t GetY () const
 Get the Y dimension.
 
void SetWidth (uint32_t width)
 Set the Width.
 
uint32_t GetWidth () const
 Get the Width.
 
void SetHeight (uint32_t width)
 Set the Height.
 
uint32_t GetHeight () const
 Get the Height.
 
widget::WidgetEnum GetType () const
 Get the Type object.
 
RendererGvaGetRenderer () const
 Get the Renderer object.
 
void SetStateText (LabelStates state)
 Set the State Text of an on screen label.
 
void SetStateLabel (const LabelStates state)
 Set the State Label object.
 
uint32_t GetStateTextColour (LabelStates state) const
 Get the State Text Colour object.
 

Additional Inherited Members

- Data Fields inherited from gva::WidgetX
uint32_t x_ = 0
 The widget x location in pixels.
 
uint32_t y_ = 0
 The widget y location in pixels.
 
uint32_t width_ = 0
 The widget width in pixels.
 
uint32_t height_ = 0
 The widget height in pixels.
 

Detailed Description

Class defining the mode widget.

Constructor & Destructor Documentation

◆ WidgetMessageBox()

gva::WidgetMessageBox::WidgetMessageBox ( const RendererGva renderer,
TouchGva touch 
)
explicit

Construct a new Widget Keyboard object.

Parameters
rendererThe underlying renderer, should be cairo
touchThe touch object

Member Function Documentation

◆ Draw()

void gva::WidgetMessageBox::Draw ( )
finalvirtual

Draw the current widget.

Implements gva::WidgetX.

◆ GetWidgetName()

std::string gva::WidgetMessageBox::GetWidgetName ( ) const
inlinefinalvirtual

Get the Widget Name attribute.

Returns
std::string

Implements gva::WidgetX.

◆ SetMessage()

void gva::WidgetMessageBox::SetMessage ( const std::string_view  message_text,
widget::IconType  icon 
)

Set the Message text and icon.

Parameters
message_textthe supplementary information used in the massage box
iconthe icon to display with the message

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