Java Graphics Methods

Java Graphics Methods

Java supports graphics. Drawing different geometrical figures is known as graphics. Java comes with java.awt.Graphics many methods of drawing.

Following programs use Frame or Applet window to draw figures.

A. Basic Programs

1. Graphics – Introduction

B. For the usage of methods of Graphics class

1. For darwLine(): Drawing Lines
2. For drawString(): Drawing Strings
3. For drawRect(): Drawing Right-angled Rectangles
4. For drawRoundRect(): Drawing Round Cornered Rectangles
5. For draw3DRect(): Drawing 3-D Rectangles
6. For drawOval(): Drawing Ovals
7. For drawArc(): Drawing Arcs
8. For drawPolygon(): Drawing Polygons (Graphics in Applets)
9. For drawImage(): Drawing Images
10. No draw Circle(): Drawing Circles (Graphics with Applets)

11. Special Figures: Drawing Cylinder, Cube, Circle

C. Graphics indepth

1. All Geometrical Figures at a glance

Leave a Reply

Your email address will not be published. Required fields are marked *