#include <rounded_rect.h>
Public Member Functions | |
Construction | |
| CL_RoundedRect (CL_Sizef size, float rounding_in_pixels=5.0f) | |
| Constructs a RoundedRect. | |
| virtual | ~CL_RoundedRect () |
Attributes | |
| CL_Sizef | get_size () const |
| Returns the base rectangle. | |
| float | get_width () const |
| Returns the width of the rectangle. | |
| float | get_height () const |
| Returns the height of the rectangle. | |
| float | get_rounding () const |
| Returns the distance from a corner (in pixels) at which the rounding starts. | |
| CL_Pointf | get_control_point_tl () const |
| Returns the positions of the top-left corners conic bezier control point. | |
| CL_Pointf | get_control_point_tr () const |
| Returns the positions of the top-right corners conic bezier control point. | |
| CL_Pointf | get_control_point_bl () const |
| Returns the positions of the bottom-left corners conic bezier control point. | |
| CL_Pointf | get_control_point_br () const |
| Returns the positions of the bottom-right corners conic bezier control point. | |
| CL_Sizef | get_rounding_top_left () const |
| Returns the relative offset (0.0-1.0) to the center of the edges connected to the corner. | |
| CL_Sizef | get_rounding_top_right () const |
| Returns the relative offset (0.0-1.0) to the center of the edges connected to the corner. | |
| CL_Sizef | get_rounding_bottom_left () const |
| Returns the relative offset (0.0-1.0) to the center of the edges connected to the corner. | |
| CL_Sizef | get_rounding_bottom_right () const |
| Returns the relative offset (0.0-1.0) to the center of the edges connected to the corner. | |
Operations | |
| void | draw (CL_GraphicContext &gc, const CL_Pointf &position, const CL_Colorf &color, CL_Origin origin=origin_top_left) |
| Draw the rectangle outline. | |
| void | draw (CL_GraphicContext &gc, const CL_Pointf &position, const CL_Gradient &gradient, CL_Origin origin=origin_top_left) |
| void | fill (CL_GraphicContext &gc, const CL_Pointf &position, const CL_Colorf &color, CL_Origin origin=origin_top_left) |
| Fill the rectangle. | |
| void | fill (CL_GraphicContext &gc, const CL_Pointf &position, const CL_Gradient &gradient, CL_Origin origin=origin_top_left) |
| void | set_size (const CL_Sizef &size) |
| Set the size of the base rectangle. | |
| void | set_control_point_tl (const CL_Pointf &pos) |
| Set the position of the top-left corners conic bezier control point. | |
| void | set_control_point_tr (const CL_Pointf &pos) |
| Set the positions of the top-right corners conic bezier control point. | |
| void | set_control_point_bl (const CL_Pointf &pos) |
| Set the positions of the bottom-left corners conic bezier control point. | |
| void | set_control_point_br (const CL_Pointf &pos) |
| Set the positions of the bottom-right corners conic bezier control point. | |
| void | set_rounding (float offset_pixels) |
| Set the distance from a corner (in pixels) at which the rounding starts. | |
| void | set_rounding_top_left (const CL_Sizef &offset) |
| Set the relative offset (0.0-1.0) to the center of the edges connected to the corner. | |
| void | set_rounding_top_right (const CL_Sizef &offset) |
| Set the relative offset (0.0-1.0) to the center of the edges connected to the corner. | |
| void | set_rounding_bottom_left (const CL_Sizef &offset) |
| Set the relative offset (0.0-1.0) to the center of the edges connected to the corner. | |
| void | set_rounding_bottom_right (const CL_Sizef &offset) |
| Set the relative offset (0.0-1.0) to the center of the edges connected to the corner. | |
|
||||||||||||
|
Constructs a RoundedRect.
|
|
|
|
|
||||||||||||||||||||
|
|
|
||||||||||||||||||||
|
Draw the rectangle outline.
|
|
||||||||||||||||||||
|
|
|
||||||||||||||||||||
|
Fill the rectangle.
|
|
|
Returns the positions of the bottom-left corners conic bezier control point.
|
|
|
Returns the positions of the bottom-right corners conic bezier control point.
|
|
|
Returns the positions of the top-left corners conic bezier control point.
|
|
|
Returns the positions of the top-right corners conic bezier control point.
|
|
|
Returns the height of the rectangle.
|
|
|
Returns the distance from a corner (in pixels) at which the rounding starts. This value is used for corners for which no value has been specified separately. |
|
|
Returns the relative offset (0.0-1.0) to the center of the edges connected to the corner.
|
|
|
Returns the relative offset (0.0-1.0) to the center of the edges connected to the corner.
|
|
|
Returns the relative offset (0.0-1.0) to the center of the edges connected to the corner.
|
|
|
Returns the relative offset (0.0-1.0) to the center of the edges connected to the corner.
|
|
|
Returns the base rectangle.
|
|
|
Returns the width of the rectangle.
|
|
|
Set the positions of the bottom-left corners conic bezier control point.
|
|
|
Set the positions of the bottom-right corners conic bezier control point.
|
|
|
Set the position of the top-left corners conic bezier control point.
|
|
|
Set the positions of the top-right corners conic bezier control point.
|
|
|
Set the distance from a corner (in pixels) at which the rounding starts. This value is used for corners for which no value has been specified separately. |
|
|
Set the relative offset (0.0-1.0) to the center of the edges connected to the corner.
|
|
|
Set the relative offset (0.0-1.0) to the center of the edges connected to the corner.
|
|
|
Set the relative offset (0.0-1.0) to the center of the edges connected to the corner.
|
|
|
Set the relative offset (0.0-1.0) to the center of the edges connected to the corner.
|
|
|
Set the size of the base rectangle.
|
1.4.6