slint::RgbaColor Struct
template <typename T>struct RgbaColor;C++
#include <slint.h>C++
RgbaColor stores the red, green, blue and alpha components of a color with the precision of the template parameter T. For example if T is float, the values are normalized between 0 and 1. If T is uint8_t, they values range is 0 to 255.
Public Attributes
Section titled “Public Attributes”T slint::RgbaColor<T>::alpha
The alpha component.
T slint::RgbaColor<T>::red
The red component.
T slint::RgbaColor<T>::green
The green component.
T slint::RgbaColor<T>::blue
The blue component.
Public Functions
Section titled “Public Functions” RgbaColor
Section titled “ RgbaColor”slint::RgbaColor<T>::RgbaColor(const Color &col)
Creates a new RgbaColor instance from a given color. This template function is specialized and thus implemented for T == uint8_t and T == float.
RgbaColor
Section titled “ RgbaColor”slint::RgbaColor<uint8_t>::RgbaColor(const Color &color)
Constructs a new RgbaColor<uint8_t> from the color color.
RgbaColor
Section titled “ RgbaColor”slint::RgbaColor<float>::RgbaColor(const Color &color)
Constructs a new RgbaColor<float> from the color color.
© 2026 SixtyFPS GmbH