CuteHMI - Graphical User Interface (CuteHMI.GUI.0)
CuteHMI::GUI::Element Class Reference

Element. More...

Inheritance diagram for CuteHMI::GUI::Element:
CuteHMI::GUI::NumberDisplay

Public Member Functions

ColorSet currentStateColorSet ()
 Pick color set based on active, warning and alarm property states. More...
 

Properties

Units units
 Units used by the element. More...
 
Palette palette
 Palette. More...
 
ColorSet color
 This property defines current colors that should be used to draw element contents. More...
 
ColorSet colorSet
 Active color set. More...
 
bool neutral
 Denotes if element is neutral (it does not distinguish between active, inactive, warning and alarm states). More...
 
bool active
 Denotes if an item is in active state. More...
 
bool warning
 Denotes if an item is in warning state. More...
 
bool alarm
 Denotes if an item is in alarm state. More...
 
bool indirectWarning
 Denotes if item is in indirect warning state. More...
 
bool indirectAlarm
 Denotes if item is in indirect alarm state. More...
 

Detailed Description

Element.

Since
0.0

This component should be used to implement color code aware items.

Member Function Documentation

◆ currentStateColorSet()

ColorSet CuteHMI::GUI::Element::currentStateColorSet ( )

Pick color set based on active, warning and alarm property states.

Alarm takes precedence before warning and warning takes precedence over active state. For warning and alarm states this function dynamically alters the colors to carry visual information more effectively and to provide accessibility to color blind people.

Returns
appropriate color set.

Property Documentation

◆ active

bool CuteHMI::GUI::Element::active

Denotes if an item is in active state.

◆ alarm

bool CuteHMI::GUI::Element::alarm

Denotes if an item is in alarm state.

Alarm state should take precedence over warning and active states.

◆ color

ColorSet CuteHMI::GUI::Element::color

This property defines current colors that should be used to draw element contents.

By default, color properties are binded to the respective properties of active color set. However, current color values may differ from those of active color set, when color transitions take place.

◆ colorSet

ColorSet CuteHMI::GUI::Element::colorSet

Active color set.

Normally this is controlled by currentStateColorSet() function, which sets appropriate color according to the state of active, warning and alarm properties. Neutral elements are binded to neutral color set.

◆ indirectAlarm

bool CuteHMI::GUI::Element::indirectAlarm

Denotes if item is in indirect alarm state.

This kinf of alarm may be handy when alarm is diagnosed from indirect measurments.

◆ indirectWarning

bool CuteHMI::GUI::Element::indirectWarning

Denotes if item is in indirect warning state.

This kinf of warning may be handy when warning is diagnosed from indirect measurments.

◆ neutral

bool CuteHMI::GUI::Element::neutral

Denotes if element is neutral (it does not distinguish between active, inactive, warning and alarm states).

◆ palette

Palette CuteHMI::GUI::Element::palette

Palette.

Palette to be used by an element.

◆ units

Units CuteHMI::GUI::Element::units

Units used by the element.

◆ warning

bool CuteHMI::GUI::Element::warning

Denotes if an item is in warning state.

Warning state should take precedence over active state.