GraffitiSuite Docs
Docs
Polygon
Loading document parsing libraries...
# Polygon Class Inherits Shape ## Compatibility ### Framework API Version | 1.0 | 2.0 | | :---: | :---: | | True | True | ### Web | 32-Bit | 64-Bit | | :---: | :---: | | True | True | ## Methods | Name | Parameters | Return Type | Description | | --- | :---: | :---: | --- | | Constructor | path() as GraffitiMap.Point | (None) | Creates a new instance of the class. | | Attributes | Hidden | toJavaScript | | | Attributes | Hidden | toJSON | | ## Properties | Name | Type | Default Value | Description | | --- | :---: | :---: | --- | | FillColor | Color | Nil | | | path() | GraffitiMap.Point | Nil | Path global coordinates. | | StrokePosition | GraffitiMap.Shapes.StrokePositions | Nil | | ## Examples ### Sample Polygon ``` var polygonPath() as GraffitiMap.Point polygonPath.Add( new GraffitiMap.Point( 25.774, -80.19 ) ) polygonPath.Add( new GraffitiMap.Point( 18.466, -66.118 ) ) polygonPath.Add( new GraffitiMap.Point( 32.321, -64.757 ) ) var bermudaTriangle as new GraffitiMap.Shapes.Polygon( polygonPath ) bermudaTriangle.Tooltip = "<strong>Strange</strong> stuff happens here?<br />I guess?<br />I mean like...aliens and junk?<br />IDK!" bermudaTriangle.FillColor = color.RGB( 255, 0, 0, 100 ) bermudaTriangle.StrokeColor = color.RGB( 255, 0, 0, 200 ) bermudaTriangle.StrokeWeight = 2 bermudaTriangle.StrokePosition = GraffitiMap.Shapes.StrokePositions.Outside bermudaTriangle.Draggable = True bermudaTriangle.Editable = True me.AddShape( bermudaTriangle ) ```