|
C-Menu 0.2.9
A User Interface Toolkit
|
Structure representing a color in the UI. More...
#include <ui_backend.h>
Data Fields | |
| union { | |
| struct { | |
| uint8_t a | |
| uint8_t b | |
| uint8_t g | |
| uint8_t r | |
| } | |
| struct { | |
| uint32_t rgba | |
| } | |
| }; | |
| union { | |
| struct { | |
| uint8_t a | |
| uint8_t b | |
| uint8_t g | |
| uint8_t r | |
| } | |
| struct { | |
| uint32_t rgba | |
| } | |
| }; | |
| uint32_t | idx |
| uint32_t | index |
| bool | use_rgb |
Structure representing a color in the UI.
The UiColor structure represents a color that can be used for foreground and background styling in the UI. It includes RGB values for true color support, as well as an index for palette-based colors. The use_rgb flag indicates whether the RGB values should be used (true) or if the index should be used to reference a color from a predefined palette (false). This allows for flexibility in color representation, supporting both modern terminals with true color capabilities and older terminals that rely on a limited color palette.
Definition at line 129 of file ui_backend.h.
| union { ... } UiColor |
| union { ... } UiColor |
| uint8_t UiColor::a |
Definition at line 132 of file ui_backend.h.
| uint8_t UiColor::b |
Definition at line 133 of file ui_backend.h.
| uint8_t UiColor::g |
Definition at line 134 of file ui_backend.h.
| uint32_t UiColor::idx |
Definition at line 19 of file ui_colors.c.
| uint32_t UiColor::index |
Definition at line 142 of file ui_backend.h.
| uint8_t UiColor::r |
Definition at line 135 of file ui_backend.h.
| uint32_t UiColor::rgba |
Definition at line 138 of file ui_backend.h.
| bool UiColor::use_rgb |
Definition at line 141 of file ui_backend.h.