Example
Example: Suppose you have a component whose job it is to draw a red rectangle
Using the AWT drawing model:
public void paint( Graphics g ) {
g.setColor( Color.red );
g.fillRect( 300, 300, 200, 100 );
}
Previous slide
Next slide
Back to first slide
View graphic version