PolyLine
A series of connected line segments. Unlike most label objects, PolyLine does not use a position anchor — coordinates are specified directly in the points array.
Mandatory properties
| Property | Type | Description |
|---|---|---|
| type | string | Must be PolyLine. |
| points | array | Flat array of coordinates: [x0, y0, x1, y1, ...]. Must contain at least 4 values (one segment). |
Optional properties
| Property | Type | Description |
|---|---|---|
| lineWidth | number | Line width. Default is 1. |
| color | string | Line color. May contain dynamic text. Default is black. |
| segments | array | Dash pattern as alternating [dashLength, gapLength, ...] values. If omitted, a solid line is drawn. |
Example
{
"type": "PolyLine",
"points": [10.0, 10.0, 50.0, 10.0, 50.0, 40.0],
"lineWidth": 1.0,
"color": "black"
}
Dashed line example:
{
"type": "PolyLine",
"points": [10.0, 20.0, 90.0, 20.0],
"lineWidth": 0.5,
"segments": [5.0, 2.0]
}