com.darwinsys.graphics
Class ColorName

java.lang.Object
  extended by com.darwinsys.graphics.ColorName

public class ColorName
extends java.lang.Object

A simple class for looking up Java AWT Color Names; I got tired of including this code in every program that needed it! (yes, this IS a hint to JavaSoft.).
TODO: Rewrite XColor from javasrc as a subclass of this.

Author:
Ian Darwin, delinted by Bill Heinze

Field Summary
static java.awt.Color FALLBACK_COLOR
           
 
Constructor Summary
ColorName()
           
 
Method Summary
static java.awt.Color getColor(java.lang.String name)
          Lookup a given string
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

FALLBACK_COLOR

public static final java.awt.Color FALLBACK_COLOR
Constructor Detail

ColorName

public ColorName()
Method Detail

getColor

public static java.awt.Color getColor(java.lang.String name)
Lookup a given string

Returns:
The java.awt.Color corresponding, or null.


Copyright © 1996-2004 Ian F. Darwin. See license.html for usage license.