AddPolyline

AddPolyline ( scanDirection ;​ listOfCoords ;​ lineStroke ;​ lineColor ;​ lineColorVariant ;​ shadowEffect ;​ shadowColor )

Argument Type Range Default Note
scanDirection int 1..2 xxyy
listOfCoords num[] -inf..+inf (required)
lineStroke num[] 0..1000 1 Dimension:[pt]
lineColor rgba 0..255 black
lineColorVariant int -1..128 solid
shadowEffect num[] -1000..1000 0
shadowColor rgba 0..255 #888a
Examples

AddPolyline(xxyy;​50 50 150 150 150 100 50 250)

AddPolyline(xyxy;​50 50 150 150 150 100 50 250;​2;​blue)

Description

The AddPolyline() function makes it possible to draw continuous straight lines whose stroke (thickness, dash pattern), color and shadow can be varied. The arguments scanDirection and listOfCoords are explained in combination with the AddPolygon() function.

ADD_POLYLINE_01
1

OpenDrawing(100;​100)

2

AddPolyline(xyxy;​

3

50.0 10.0

4

88.0 37.6

5

73.5 82.4

6

26.5 82.4

7

12.0 37.6

8

50.0 10.0;​

9

4.5;​steelBlue;​solid)

10

CloseDrawing()

ADD_POLYLINE_01
ADD_POLYLINE_02
1

OpenDrawing(100;​100)

2

AddPolyline(xyxy;​

3

50.0 10.0

4

59.0 37.6

5

88.0 37.6

6

64.6 54.7

7

73.5 82.4

8

50.0 65.3

9

26.5 82.4

10

35.4 54.7

11

12.0 37.6

12

41.0 37.6

13

50.0 10.0;​

14

3.5;​0 0 0 50;​solid)

15

CloseDrawing()

ADD_POLYLINE_02
ADD_POLYLINE_03
1

OpenDrawing(100;​100)

2

AddPolyline(xyxy;​

3

50.0 10.0

4

73.5 82.4

5

12.0 37.6

6

88.0 37.6

7

26.5 82.4

8

50.0 10.0;​

9

2.0;​steelBlue;​solid;​

10

0 0 3;​0 128 128 150) /* Shadow */

11

CloseDrawing()

ADD_POLYLINE_03
Scroll to Top