System Colors

In Java 1.1, the java.awt.SystemColor class is a subclass of java.awt.Color which provides color constants that match native component colors. For example, if you wanted to make the background color of your applet, the same as the background color of a window, you might use this init() method:

public void paint (Graphics g) {

  g.fillRect(0, 0, this.getSize().width, this.getSize().height);

These are the available system colors:

Previous | Next | Top | Cafe au Lait

Copyright 1997, 1998 Elliotte Rusty Harold
Last Modified October 21, 1999