C4 Engine
C4 Engine API Documentation

class ColorWidget

Defined in:  C4Widgets.h
The ColorWidget class represents an interface widget that displays a color picking box.

class ColorWidget final : public RectangleWidget


ColorWidget(const Vector2D& size, const ColorRGBA& color = Color::white);

size The size of the color box, in pixels.
color The color that is initially displayed in the color box.
The ColorWidget class displays a color selection box that displays a color picker dialog when clicked.

The default widget color corresponds to the kWidgetColorBorder color type and determines the color of the border.
Base Classes
RectangleWidget The color widget is rendered as a rectangular box.
Wiki Articles

Color Widget