module:RegularPolygon

Regular polygon class
regular-polygon demo

Constructor

new module:RegularPolygon(position, nbSides, radiusopt, optionsopt)

Regular polygon constructor

Parameters:
NameTypeAttributesDefaultDescription
positionPositionDefinition

Center of the polygon

nbSidesNumber

Number of sides

radiusNumber<optional>
0

Distance between center and outer points

optionsComponentOptions<optional>

Drawing options

Extends