DRAWPOLY
DRAWPOLY array [,x-origin,y-origin [, scalef [, color]]] [COLOR color] [FILLED]
Draws a polyline. The array contains all the vertices of the polyline and can be defined as follow:
- [[x1,y1], [x2,y2], … ,[xn,yn]]
- [x1,y1, x2,y2, … , xn,yn]
Scaling factor scalef is applied after moving to the x- and y-origin.
Example 1: Polygon array with points
0,50], [50,0], [100,50], [0,50]]
P = [[
drawpoly P ' Draw poly
drawpoly P, 200,200 ' Draw poly with offset
drawpoly P, 200,200, 1.5 COLOR 4 ' Draw poly with offset, scaling and color
Example 2: Polygon array without points
0,50, 50,0, 100,50, 0,50] ' Even elements -> x
P = [' Uneven elements -> y
drawpoly P ' Draw poly
drawpoly P, 200,200 ' Draw poly with offset
drawpoly P, 200,200, 1.5 COLOR 4 ' Draw poly with offset, scaling and color
Code samples using DRAWPOLY
Graphics
ARC
CHART
CIRCLE
COLOR
DRAW
DRAWPOLY
IMAGE
LINE
PAINT
PEN
PLOT
POINT
PSET
RECT
RGB
RGBF
SHOWPAGE
TEXTHEIGHT
TEXTWIDTH
TXTH
TXTW
VIEW
WINDOW
XMAX
XPOS
YMAX
YPOS
If there is insufficient information on this page and you wish learn more about DRAWPOLY,
please send an email to smallbasic@gmail.com. You can help to improve information about
DRAWPOLY by submitting a pull request,
click View Source for details. Note, an offline language reference text file is also available - see the Download section.