![]() |
Bridges-C++
3.2.0
Bridges(C++API)
|
#include <Polygon.h>
This class defines a polygon and is part of the symbol collection. A polygon has a set of vertices, with vertices connected by line segments. It differs from the polyline in the sense that the last and first vertex are connect to close the shape.
Public Member Functions | |
Polygon () | |
default constructor More... | |
Polygon (vector< float > pts) | |
constructor, given a set of points More... | |
virtual string | getDataStructType () |
This method gets the name of the data type. More... | |
virtual string | getName () const |
This method gets the name of the shape. More... | |
void | setPolygon (vector< float > pts) |
constructs a polygon, given a set of points More... | |
![]() | |
Polyline () | |
default constructor More... | |
Polyline (vector< float > pts) | |
Construct a polyline from sequence of points. More... | |
string | getDataStructType () |
Get the name of the data type. More... | |
string | getName () const |
This method gets the name of the shape. More... | |
void | addPoint (float x, float y) |
This method adds a point to the polyline. More... | |
vector< float > | getPoints () |
This method returns the point list of the polyline. More... | |
void | setPolyline (vector< float > pts) |
Construct a polyline from sequence of points. More... | |
void | translate (float tx, float ty) |
Translate the polyline. More... | |
void | rotate (float angle) |
rotate the polyline about its center More... | |
void | scale (float sx, float sy) |
Scale the polyline about its center. More... | |
void | getCenter (float *center) |
Get center of polyline - use its bounding box. More... | |
vector< float > | getDimensions () const |
This method returns the dimensions of the shape: min and max values in X and Y. More... | |
const string | getSymbolRepresentation () const |
This method returns the JSON representation of the shape. More... | |
![]() | |
Symbol () | |
default constructor More... | |
Symbol (string symb) | |
Create a symbol of type "symb". More... | |
int | getIdentifier () |
return the symbol identifier. More... | |
void | setLabel (string lbl) |
Set the symbol label. More... | |
string | getLabel () const |
Get the symbol label. More... | |
void | setFillColor (Color c) |
Set the symbol fill color. More... | |
void | setFillColor (string c) |
This method sets the symbol fill color. More... | |
Color | getFillColor () |
This method gets fill color. More... | |
void | setStrokeColor (Color c) |
void | setStrokeColor (string c) |
This method sets the symbol stroke color. More... | |
Color | getStrokeColor () |
This method gets stroke color. More... | |
void | setStrokeWidth (float strk_width) |
This method sets the symbol stroke width. More... | |
float | getStrokeWidth () |
This method gets stroke width. More... | |
void | setOpacity (float op) |
This method sets the symbol opacity. More... | |
float | getOpacity () |
This method gets symbol opacity. More... | |
void | setStrokeDash (int dash) |
This method sets the stroke dash level. More... | |
int | getStrokeDash () |
This method gets stroke dash level. More... | |
void | setLocation (int x, int y) |
This method sets the symbol location. More... | |
void | setLocation (double x, double y) |
This method sets the symbol location. More... | |
void | setCenter (float x, float y) |
This method sets the symbol location. More... | |
void | setLocation (float x, float y) |
This method sets the ssymbol location. More... | |
const float * | getLocation () const |
This method gets the symbol location. More... | |
string | getName () const |
This method gets the name of the symbol. More... | |
Additional Inherited Members | |
![]() | |
void | setShapeType (string s) |
Set the shape type. More... | |
string | getShapeType () const |
void | translatePoint (float *pt, float tx, float ty) |
Translate a 2D point. More... | |
void | scalePoint (float *pt, float sx, float sy) |
Scale a 2D point. More... | |
void | rotatePoint (float *pt, float angle) |
Rotate a 2D point (about Z) More... | |
const string | getSymbolAttributeRepresentation () const |
Get the JSON of the symbol representation. More... | |
![]() | |
vector< float > | points |
|
inline |
default constructor
|
inline |
constructor, given a set of points
pts | to construct polygon |
|
inlinevirtual |
This method gets the name of the data type.
|
inlinevirtual |
This method gets the name of the shape.
|
inline |
constructs a polygon, given a set of points
pts | to construct polygon |