Constructor # new module:Polygon(positionDefinition, points, optionsopt) Polygon constructor Parameters: Name Type Attributes Description positionDefinition PositionDefinition Any position points Array.<PositionDefinition> Set of vertices relative to position defining the polygon options ComponentOptions <optional> Drawing options Source: modules/polygon/polygon.js, line 14 Extends module:Component Members # points :Array.<Position> Type: Array.<Position> Source: modules/polygon/polygon.js, line 31 Methods # (static) from(definition) → {Polygon} Parameters: Name Type Description definition Object Polygon definition Source: modules/polygon/polygon.js, line 61 Returns: Type Polygon # trace(path) → {Polygon} Draw the polygon Parameters: Name Type Description path Path2D Current drawing path Overrides: module:Component#trace Source: modules/polygon/polygon.js, line 39 Returns: Itself Type Polygon