Basic HTML version of Foils prepared May 19 99

Foil 11 Example

From Java Media Framework API's Basic Information Track Computational Science Course CPS616 -- Spring Semester 1999. by Byeongseob Ki, Scott Klasky, Nancy McCracken


1 Example: Suppose you have a component whose job it is to draw a red rectangle
2
  • Using the AWT drawing model:
3 public void paint( Graphics g ) {
4 g.setColor( Color.red );
5 g.fillRect( 300, 300, 200, 100 );
6 }

in Table To:


© Northeast Parallel Architectures Center, Syracuse University, npac@npac.syr.edu

If you have any comments about this server, send e-mail to webmaster@npac.syr.edu.

Page produced by wwwfoil on Mon Jul 5 1999