|
My Project
|
Implementation of a square figure. More...
#include <square.h>


Public Member Functions | |
| square (int x, int y, int side) | |
| Constructor. | |
| void | set_line_color (Color color) override |
| Set line color. | |
| void | set_background_color (Color color) override |
| Set the background color of the shape. | |
| void | set_coordinates (int x, int y) override |
| Setting new coordinates for the figure. | |
| void | draw () override |
| Drawing a figure. | |
| std::tuple< int, int > | get_coordinates () override |
| Returns the coordinates of a figure. | |
| void | set_size (int side) |
| Set square size. | |
Public Member Functions inherited from graphic_primitive | |
| graphic_primitive () | |
| Constructor. | |
| virtual | ~graphic_primitive () |
| Destructor. | |
Additional Inherited Members | |
Public Types inherited from graphic_primitive | |
| enum class | Color { RED , GREEN , BLUE } |
| Acceptable colors. More... | |
| enum class | Type { CICLE , RECTANGLE , SQUARE , TRIANGLE } |
| Acceptable shape types. More... | |
Implementation of a square figure.
| square::square | ( | int | x, |
| int | y, | ||
| int | side ) |
Constructor.
|
overridevirtual |
Drawing a figure.
Implements graphic_primitive.
|
overridevirtual |
Returns the coordinates of a figure.
Implements graphic_primitive.
|
overridevirtual |
Set the background color of the shape.
Implements graphic_primitive.
|
overridevirtual |
Setting new coordinates for the figure.
Implements graphic_primitive.
|
overridevirtual |
Set line color.
Implements graphic_primitive.
| void square::set_size | ( | int | side | ) |
Set square size.