A set of connected line segments
PtWidget → PtBasic → PtGraphic → PtPolygon
For more information, see the diagram of the widget hierarchy.
<photon/PtPolygon.h>
You can use the PtPolygon widget to draw a set of connected line segments, called a polyline, from the vertices of the line segments.
The points that you specify in the Pt_ARG_POINTS resource are the vertices of the polyline or polygon. These points are relative to the widget's Pt_ARG_ORIGIN. For more information, see PtGraphic.
For a polygon, the last vertex doesn't have to be the same as the first; the widget can close the polygon for you.
You can use Pt_ARG_POLYGON_FLAGS to specify:
Resource | C type | Pt type | Default |
---|---|---|---|
Pt_ARG_POLYGON_FLAGS | unsigned short | Flag | 0 |
C type | Pt type | Default |
---|---|---|
unsigned short | Flag | 0 |
This resource defines the type of polygon to be drawn. You can OR the following flag bits (defined in <photon/Pg.h>):
The default setting of this resource is 0; that is, no flags have been set.
If the widget modifies an inherited resource, the “Default override” column indicates the new value. This modification affects any subclasses of the widget.