gigawidgets 0.3.55
A wxWidgets-style UI library for the Arduino Giga Display Shield.
 
Loading...
Searching...
No Matches
ellipse.hpp
Go to the documentation of this file.
1
2#pragma once
3
4#include "../../radius.hpp"
5#include "../shape.hpp"
6
7namespace ui {
8
12struct Ellipse : public Shape {
14 bool fill;
21
30
31 void renderAt(const Coords &coords, const shader_t &shader) const override;
32
33 Size getSize() const override;
34};
35
36} // namespace ui
uint16_t color_t
An RGB565 color value. 5 bits red, 6 bits green, 5 bits blue.
Definition color.hpp:13
uint16_t radius_t
A non-negative size for the pixel radius of curved shapes.
Definition radius.hpp:12
shader_animated_t shader_t
A pixel shader that may or may not update based on the current time.
Definition renderable.hpp:48
A struct for storing the pixel coordinates of various UI elements.
Definition coords.hpp:17
An ellipse.
Definition ellipse.hpp:12
bool fill
Whether the shape is filled or just an outline.
Definition ellipse.hpp:14
radius_t radius1
The first radius of the ellipse.
Definition ellipse.hpp:18
Size getSize() const override
Get the size of the renderable.
color_t color
The color of the ellipse.
Definition ellipse.hpp:16
void renderAt(const Coords &coords, const shader_t &shader) const override
Display the renderable directly onto the screen.
Ellipse(color_t color, radius_t radius1, radius_t radius2, bool fill=false)
Construct an ellipse.
radius_t radius2
The second radius of the ellipse.
Definition ellipse.hpp:20
The common interface for rendering arbitrary shapes.
Definition shape.hpp:11
A struct that holds the number of pixels that a widget would take up on the screen.
Definition size.hpp:17