您的位置:寻梦网首页编程乐园Java天地Core JavaJava Lecture Notes

Introduction

Content

Apply

Reflect

Extend

previous.gif
 (3087 bytes)

next.gif
 (2959 bytes)

 

Content Index

Content Page # 10

Polylines and Polygons

A common source of confusion is the difference between a ‘polygon' and a 'polyline'. The difference is that a polygon is always closed (starts and ends at the same points), and can therefore be drawn filled (solid). A polyline cannot be filled. Rectangles, ‘round' rectangles and ovals can be drawn filled or unfilled. For example Graphics.drawRect() draws the outline of a rectangle, while Graphics.fillRect()draws a solid rectangle. 

basicline.gif (169 bytes)

RITSEC - Global Campus
Copyright ?1999 RITSEC- Middlesex University. All rights reserved.
webmaster@globalcampus.com.eg