C4 Engine
C4 Engine API Documentation

class CircleWidget

Defined in:  C4Widgets.h
The CircleWidget class represents an interface widget that displays a circle or ellipse.
Definition

class CircleWidget final : public FillableWidget

Constructor

CircleWidget(const Vector2D& size, float thickness, const ColorRGBA& stroke);

CircleWidget(const Vector2D& size, float thickness, const ColorRGBA& stroke, const ColorRGBA& fill);

CircleWidget(const Vector2D& size, const ColorRGBA& fill);

Parameters
size The size of the circle, in pixels.
thickness The thickness of the stroke, in pixels.
stroke The initial color of the stroke.
fill The initial color of the fill.
Description
The CircleWidget class is used to render a circle or ellipse.

If a constructor without the fill parameter is called, then the circle has no fill. If a constructor without the thickness and stroke parameters is called, then the circle has no stroke.

The default widget color corresponds to the kWidgetColorLine color type. The kWidgetColorFill color types is also supported, and it controls the circle's fill color.
Base Classes
FillableWidget Circle widgets are composed of fills and strokes rendered with Slug.
See Also

RectangleWidget

LineWidget

Wiki Articles

Circle Widget