Next Prev Up Top Contents Index

2.5.3.2 Accessors for CLIM Polygons and Polylines

The following generic functions comprise the polygon and polyline protocol. All classes that are subclasses of polygon or polyline must implement methods for them. Some of the functions take an argument polygon-or-polyline , which may be a polygon or a polyline.

polygon-points [Generic Function]

Arguments: polygon-or-polyline

Summary: Returns a sequence of points that specify the segments in polygon-or-polyline . This function returns objects that reveal CLIM's internal state; do not modify those objects.

map-over-polygon-coordinates [Generic Function]

Arguments: function polygon-or-polyline

Summary: Applies function to all of the coordinates of the vertices of polygon-or-polyline . function is a function of two arguments, the x and y coordinates of the vertex; it has dynamic extent.

map-over-polygon-segments [Generic Function]

Arguments: function polygon-or-polyline

Summary: Applies function to the segments that compose polygon-or-polyline . function is a function of four arguments, the x and y coordinates of the start of the segment, and the x and y coordinates of the end of the segment; it has dynamic extent. When map-over-polygon-segments is called on a closed polyline, it will call function on the segment that connects the last point back to the first point.

polyline-closed [Generic Function]

Arguments: polyline

Summary: Returns t if the polyline polyline is closed; otherwise, it returns nil .


CommonLisp Interface Manager 2.0 User's Guide - 8 Aug 2003

Next Prev Up Top Contents Index