![]() |
Bayeux
3.4.1
Core Foundation library for SuperNEMO
|
A LED widget with ON/OFF(/INDETERMINATE) status. More...
#include <bayeux/datatools/qt/led.h>
Public Types | |
| enum | led_color_type { Red = 0, Green, Yellow, Grey, Orange, Purple, Blue } |
| Supported colors. More... | |
| enum | led_shape_type { Circle = 0, Square, Triangle, Rounded } |
| Supported shapes. More... | |
| enum | value_type { ValueOff = 0, ValueOn = 1, ValueIndeterminate = 2 } |
Public Slots | |
| void | set_value (bool) |
| Set the value. More... | |
| void | set_indeterminate () |
| Set the inderminate value. More... | |
| void | set (const boost::logic::tribool t_) |
| Set the value. More... | |
| void | set_on_color (led_color_type) |
| Set the ON color. More... | |
| void | set_off_color (led_color_type) |
| Set the OFF color. More... | |
| void | set_indeterminate_color (led_color_type) |
| Set the indeterminate color. More... | |
| void | set_shape (led_shape_type) |
| Set the shape. More... | |
| void | toggle_value () |
| Toggle value. More... | |
Public Member Functions | |
| led (QWidget *parent=0) | |
| Default constructor. More... | |
| led (led_shape_type shape_, led_color_type on_color_, led_color_type off_color_, QWidget *parent=0) | |
| Default constructor. More... | |
| led (led_shape_type shape_, led_color_type on_color_, led_color_type off_color_, led_color_type indeterminate_color_, QWidget *parent=0) | |
| Default constructor. More... | |
| virtual | ~led () |
| Destructor. More... | |
| bool | get_value () const |
| Return the value. More... | |
| led_color_type | get_on_color () const |
| Return the ON color. More... | |
| led_color_type | get_off_color () const |
| Return the OFF color. More... | |
| led_color_type | get_indeterminate_color () const |
| Return the indeterminate color. More... | |
| led_shape_type | get_shape () const |
| Return the shape. More... | |
Protected Member Functions | |
| virtual void | paintEvent (QPaintEvent *event) |
| Qt widget interface. More... | |
| virtual QSize | sizeHint () const |
| Qt widget interface. More... | |
| void | _set_default () |
| Set default attributes. More... | |
Protected Attributes | |
| bool | _three_states_ = false |
| value_type | _value |
| Current value (On/Off) More... | |
| led_color_type | _on_color |
| On color. More... | |
| led_color_type | _off_color |
| Off color. More... | |
| led_color_type | _indeterminate_color |
| Indeterminate color. More... | |
| led_shape_type | _shape |
| Current shape of the LED. More... | |
| QStringList | _shapes |
| List of supported shapes. More... | |
| QStringList | _colors |
| List of supported colors. More... | |
Properties | |
| bool | value |
| led_color_type | on_color |
| led_color_type | off_color |
| led_color_type | indeterminate_color |
| led_shape_type | shape |
A LED widget with ON/OFF(/INDETERMINATE) status.
| datatools::qt::led::led | ( | QWidget * | parent = 0 | ) |
Default constructor.
| datatools::qt::led::led | ( | led_shape_type | shape_, |
| led_color_type | on_color_, | ||
| led_color_type | off_color_, | ||
| QWidget * | parent = 0 |
||
| ) |
Default constructor.
| datatools::qt::led::led | ( | led_shape_type | shape_, |
| led_color_type | on_color_, | ||
| led_color_type | off_color_, | ||
| led_color_type | indeterminate_color_, | ||
| QWidget * | parent = 0 |
||
| ) |
Default constructor.
|
virtual |
Destructor.
|
protected |
Set default attributes.
|
inline |
Return the indeterminate color.
|
inline |
Return the OFF color.
|
inline |
Return the ON color.
|
inline |
Return the shape.
|
inline |
Return the value.
|
protectedvirtual |
Qt widget interface.
|
slot |
Set the value.
|
slot |
Set the inderminate value.
|
slot |
Set the indeterminate color.
|
slot |
Set the OFF color.
|
slot |
Set the ON color.
|
slot |
Set the shape.
|
slot |
Set the value.
|
protectedvirtual |
Qt widget interface.
|
slot |
Toggle value.
|
protected |
List of supported colors.
|
protected |
Indeterminate color.
|
protected |
Off color.
|
protected |
On color.
|
protected |
Current shape of the LED.
|
protected |
List of supported shapes.
|
protected |
|
protected |
Current value (On/Off)
|
readwrite |
|
readwrite |
|
readwrite |
|
readwrite |
|
readwrite |
1.8.15