polyline()

Produces an SVG "polyline" element.

Syntax

polyline(
   points STRING )
  RETURNS om.DomNode
  1. points is a STRING defining the points of the polygon.

Usage

This function creates a "polygon" SVG DOM element from the parameters.

The points is a string contains a list of X,Y coordinates to draw the shape, in the form "x1,y1 x2,y2 ...".

Example

DEFINE n om.DomNode
LET n = fglsvgcanvas.polyline("10,10 10,20 20,20")
CALL n.setAttribute(SVGATT_STYLE, "stroke:#660000;")