XPRINT POLYLINE statement

Purpose

Draw a series of connected lines on a host printer page.

Syntax

XPRINT POLYLINE points [, rgbColor&]

Remarks

The coordinate points are specified in pixels, unless optional world coordinates have been defined with an XPRINT SCALE statement. Line width can be set using XPRINT WIDTH.  If line width is set to 1 (the default), the line style can be set with XPRINT STYLE.  XPRINT POLYLINE neither uses, nor updates, the last point referenced ( POS). If executed without a host printer attached, error 57 is generated.

points    

User-defined type that defines the number of vertices and the location of each.  There must be at least two, and no more than 1024 vertices.  The first member is a long integer point count, followed directly by the appropriate number of single precision floats to specify the actual coordinates.  Floating point coordinates are required, because of the possibility of their use as world coordinates with SCALE.  You can use a type with a scalar list, like this:

TYPE PolyPoints

  count as long

  x1 as single

  y1 as single

  x2 as single

  y2 as single

  x3 as single

  y3 as single

END TYPE

Or, you can create an array using point types, like this:

TYPE PolyPoint

  x as single

  y as single

END TYPE

 

TYPE PolyArray

  count as long

  xy(1 TO 3) as PolyPoint

END TYPE

rgbColor&

Optional RGB color of the polygon edge.  If omitted (or -1), the edge color defaults to the current foreground color for the host printer page.

See also

XPRINT ARC, XPRINT ATTACH, XPRINT BOX, XPRINT COLOR, XPRINT ELLIPSE, XPRINT LINE, XPRINT POLYGON, XPRINT STYLE, XPRINT WIDTH