17.8. Drawing Polygons and Polylines
Polygons are multisided shapes. There are several Graphics methods used to draw polygons—DrawLines draws a series of connected lines, DrawPolygon draws a closed polygon and FillPolygon draws a solid polygon. These methods are described in Fig. 17.19. The program in Fig. 17.20 allows users to draw polygons and connected lines via the methods listed in Fig. 17.19.
|DrawLines||Draws a series of connected lines. The coordinates of each point are specified in an array of Point objects. If the last point is different from the first point, the figure is not closed.|
|DrawPolygon||Draws a polygon. The coordinates of each point are specified in an array of ...|