BAP Online Manuals : Library Reference : Library by Name : filledpolygon
Previous: filledellipse
Next: findall

6.2.55. filledpolygon

draws a filled polygon

SYNOPSIS

INCLUDE 'graphlib.h'
filledpolygon(graphwin, style, [10,10,20,20,10,20])

SYNTAX

filledpolygon(Handle, Style, pointlist) (i,i,i) 

ARGUMENTS

handle(Handle) (i) Virtual file handle associated with the window.
integer(Style) (i) Color or brush to till polygon with, constants as defined in graphlib.h
intlist(pointlist) (i) list of corner points.

DESCRIPTION

Filledpolygon draws a polygon into the ´metafile´ for the graphics window associated with Handle. The polygon is filled with the color or brush defined by Style, possible values are defined as constants in '

graphlib.h

'. The pointlist consists of pairs of integers describing the corners (any number) of the polygon. The figure will be closed, so the first and last corner need not be identical. Coordinates are 'vrtual coordinates' as defined in the magegraphwin predicate. Note that the figure will only displayed after the metafile has been closed with enddraw .

EXAMPLE

makegraphwin(Handle,100,100,"Graphic Demo"),
filledpolygon(Handle, Style, [10,10,90,10,90,90,10,90]),
enddraw(Handle),
...
removewindow(Handle,1),!.

ERRORS

No runtime errors.

LAYERS

prolog-process, client-server, object

RELATED PREDICATES

makegraphwin , filledellipse , enddraw


BAP Online Manuals : Library Reference : Library by Name : filledpolygon
Previous: filledellipse
Next: findall