Chapter 15
Graphics Programming
OBJECTIVES
- To explain class hierarchy of swing components and containers
- To introduce three containers: JFrame, JPanel and JApplet
- To draw geometric shapes such as lines, arcs, ovals, rectangles, polygons and polylines using methods from Graphics class
- To generate random multilines
- To draw random rectangles
- To load images using Toolkit and ImageIcon and display them
- To design multithreaded blinking balls
- To paint random circles using JApplet
- To use Graphics2D class methods for painting geometric shapes such as lines, curves, rectangles, ellipses and arcs
- To introduce Colors, GradientPaint and TexturePaint classes
- To draw arbitrary shapes using GeneralPath class
- To apply translation, rotation, scaling and
Get JAVA Programming now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.