Multi-segments line.
More...
#include <poly-line.h>
Public Member Functions |
| PolyLine (Canvas *canvas, std::list< Point > &points) |
| PolyLine (Group *parent, std::list< Point > &points, ItemClient *client=NULL) |
virtual | ~PolyLine () |
void | SetPoints (std::list< Point > &points) |
double | Distance (double x, double y, Item **item) const |
void | Draw (cairo_t *cr, bool is_vector) const |
void | Move (double x, double y) |
| LineItem (Canvas *canvas) |
| LineItem (Group *parent, ItemClient *client=NULL) |
virtual | ~LineItem () |
GOColor | GetEffectiveLineColor () const |
void | ApplyLine (cairo_t *cr) const |
void | SetDashes (double const *dashes, int num_dashes, double offset) |
void | SetLineWidth (double val) |
double | GetLineWidth (void) const |
void | SetLineColor (GOColor val) |
GOColor | GetLineColor (void) const |
void | SetAutoColor (bool val) |
bool | GetAutoColor (void) const |
| Item (Canvas *canvas) |
| Item (Group *parent, ItemClient *client=NULL) |
virtual | ~Item () |
void | GetBounds (double &x0, double &y0, double &x1, double &y1) const |
void | Invalidate () const |
void | SetVisible (bool visible) |
virtual void | BuildPath (cairo_t *cr) const |
virtual bool | Draw (cairo_t *cr, double x0, double y0, double x1, double y1, bool is_vector) const |
bool | IsTopLevel () const |
void | SetClient (ItemClient *val) |
ItemClient * | GetClient (void) |
Group const * | GetParent (void) const |
bool | GetVisible (void) const |
void | SetOperator (cairo_operator_t val) |
cairo_operator_t | GetOperator (void) const |
Detailed Description
Multi-segments line.
Line item with several linear segments.
Definition at line 41 of file poly-line.h.
Constructor & Destructor Documentation
gccv::PolyLine::PolyLine |
( |
Canvas * |
canvas, |
|
|
std::list< Point > & |
points |
|
) |
| |
- Parameters
-
canvas | a Canvas. |
points | the vertices positions. |
Creates a new PolyLine sets it as a child of the root Group of canvas.
gccv::PolyLine::PolyLine |
( |
Group * |
parent, |
|
|
std::list< Point > & |
points, |
|
|
ItemClient * |
client = NULL |
|
) |
| |
- Parameters
-
Creates a new PolyLine inside parent and sets client as its associated ItemClient.
virtual gccv::PolyLine::~PolyLine |
( |
| ) |
|
|
virtual |
Member Function Documentation
double gccv::PolyLine::Distance |
( |
double |
x, |
|
|
double |
y, |
|
|
Item ** |
item |
|
) |
| const |
|
virtual |
void gccv::PolyLine::Draw |
( |
cairo_t * |
cr, |
|
|
bool |
is_vector |
|
) |
| const |
|
virtual |
- Parameters
-
cr | a cairo_t. |
is_vector | whether the cairo_t is a vectorial context. |
Draws the PolyLine to cr.
Reimplemented from gccv::Item.
void gccv::PolyLine::Move |
( |
double |
x, |
|
|
double |
y |
|
) |
| |
|
virtual |
- Parameters
-
x | the horizontal deplacement |
y | the vertical deplacement |
Moves the PolyLine.
Reimplemented from gccv::Item.
void gccv::PolyLine::SetPoints |
( |
std::list< Point > & |
points | ) |
|
- Parameters
-
points | the new vertices positions. |
Sets the vertices for the PolyLine instance.
void gccv::PolyLine::UpdateBounds |
( |
| ) |
|
|
protectedvirtual |
Member Data Documentation
std::list<Point> gccv::PolyLine::m_Points |
|
protected |
The documentation for this class was generated from the following file: