javax.swing.plaf.synth
Class ColorType

java.lang.Object
  extended by javax.swing.plaf.synth.ColorType

public class ColorType
extends Object

A typesafe enumeration of color types.

Since:
1.5

Field Summary
static ColorType BACKGROUND
          A constant used to identify the background color of a component.
static ColorType FOCUS
          A constant used to identify the focus color of a component.
static ColorType FOREGROUND
          A constant used to identify the foreground color of a component.
static int MAX_COUNT
          The maximum number of color types.
static ColorType TEXT_BACKGROUND
          A constant used to identify the background color of text of a component.
static ColorType TEXT_FOREGROUND
          A constant used to identify the foreground color of text of a component.
 
Constructor Summary
protected ColorType(String desc)
          Creates a new Color color type with the specified description.
 
Method Summary
 int getID()
          Returns the unique ID of the color type.
 String toString()
          Returns the textual description of the color type.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

FOREGROUND

public static final ColorType FOREGROUND
A constant used to identify the foreground color of a component.


BACKGROUND

public static final ColorType BACKGROUND
A constant used to identify the background color of a component.


TEXT_FOREGROUND

public static final ColorType TEXT_FOREGROUND
A constant used to identify the foreground color of text of a component.


TEXT_BACKGROUND

public static final ColorType TEXT_BACKGROUND
A constant used to identify the background color of text of a component.


FOCUS

public static final ColorType FOCUS
A constant used to identify the focus color of a component.


MAX_COUNT

public static final int MAX_COUNT
The maximum number of color types.

Constructor Detail

ColorType

protected ColorType(String desc)
Creates a new Color color type with the specified description.

Parameters:
desc - the textual description of the color type
Method Detail

getID

public final int getID()
Returns the unique ID of the color type.

Returns:
the unique ID of the color type

toString

public String toString()
Returns the textual description of the color type.

Overrides:
toString in class Object
Returns:
the textual description of the color type
See Also:
Object.getClass(), Object.hashCode(), Class.getName(), Integer.toHexString(int)