This documentation differs from the official API. Jadeite adds extra features to the API including: variable font sizes, constructions examples, placeholders for classes and methods, and auto-generated “See Also” links. Additionally it is missing some items found in standard Javadoc documentation, including: generics type information, “Deprecated” tags and comments, “See Also” links, along with other minor differences. Please send any questions or feedback to bam@cs.cmu.edu.


java.awt
class SystemColor

java.lang.Object extended by java.awt.Color extended by java.awt.SystemColor
All Implemented Interfaces:
Paint, Serializable

public final class SystemColor
extends Color
implements Serializable

A class to encapsulate symbolic colors representing the color of native GUI objects on a system. For systems which support the dynamic update of the system colors (when the user changes the colors) the actual RGB values of these symbolic colors will also change dynamically. In order to compare the "current" RGB value of a SystemColor object with a non-symbolic Color object, getRGB should be used rather than equals.

Note that the way in which these system colors are applied to GUI objects may vary slightly from platform to platform since GUI objects may be rendered differently on each platform.

System color values may also be available through the getDesktopProperty method on java.awt.Toolkit.


Field Summary
static SystemColor activeCaption
          The color rendered for the window-title background of the currently active window.
static SystemColor activeCaptionBorder
          The color rendered for the border around the currently active window.
static SystemColor activeCaptionText
          The color rendered for the window-title text of the currently active window.
static int ACTIVE_CAPTION
          The array index for the java.awt.SystemColor.activeCaption system color.
static int ACTIVE_CAPTION_BORDER
          The array index for the java.awt.SystemColor.activeCaptionBorder system color.
static int ACTIVE_CAPTION_TEXT
          The array index for the java.awt.SystemColor.activeCaptionText system color.
static int CONTROL
          The array index for the java.awt.SystemColor.control system color.
static SystemColor control
          The color rendered for the background of control panels and control objects, such as pushbuttons.
static SystemColor controlDkShadow
          The color rendered for dark shadow areas on 3D control objects, such as pushbuttons.
static SystemColor controlHighlight
          The color rendered for light areas of 3D control objects, such as pushbuttons.
static SystemColor controlLtHighlight
          The color rendered for highlight areas of 3D control objects, such as pushbuttons.
static SystemColor controlShadow
          The color rendered for shadow areas of 3D control objects, such as pushbuttons.
static SystemColor controlText
          The color rendered for the text of control panels and control objects, such as pushbuttons.
static int CONTROL_DK_SHADOW
          The array index for the java.awt.SystemColor.controlDkShadow system color.
static int CONTROL_HIGHLIGHT
          The array index for the java.awt.SystemColor.controlHighlight system color.
static int CONTROL_LT_HIGHLIGHT
          The array index for the java.awt.SystemColor.controlLtHighlight system color.
static int CONTROL_SHADOW
          The array index for the java.awt.SystemColor.controlShadow system color.
static int CONTROL_TEXT
          The array index for the java.awt.SystemColor.controlText system color.
static int DESKTOP
          The array index for the java.awt.SystemColor.desktop system color.
static SystemColor desktop
          The color rendered for the background of the desktop.
static SystemColor inactiveCaption
          The color rendered for the window-title background of inactive windows.
static SystemColor inactiveCaptionBorder
          The color rendered for the border around inactive windows.
static SystemColor inactiveCaptionText
          The color rendered for the window-title text of inactive windows.
static int INACTIVE_CAPTION
          The array index for the java.awt.SystemColor.inactiveCaption system color.
static int INACTIVE_CAPTION_BORDER
          The array index for the java.awt.SystemColor.inactiveCaptionBorder system color.
static int INACTIVE_CAPTION_TEXT
          The array index for the java.awt.SystemColor.inactiveCaptionText system color.
static int INFO
          The array index for the java.awt.SystemColor.info system color.
static SystemColor info
          The color rendered for the background of tooltips or spot help.
static SystemColor infoText
          The color rendered for the text of tooltips or spot help.
static int INFO_TEXT
          The array index for the java.awt.SystemColor.infoText system color.
static int MENU
          The array index for the java.awt.SystemColor.menu system color.
static SystemColor menu
          The color rendered for the background of menus.
static SystemColor menuText
          The color rendered for the text of menus.
static int MENU_TEXT
          The array index for the java.awt.SystemColor.menuText system color.
static int NUM_COLORS
          The number of system colors in the array.
static int SCROLLBAR
          The array index for the java.awt.SystemColor.scrollbar system color.
static SystemColor scrollbar
          The color rendered for the background of scrollbars.
static int TEXT
          The array index for the java.awt.SystemColor.text system color.
static SystemColor text
          The color rendered for the background of text control objects, such as textfields and comboboxes.
static SystemColor textHighlight
          The color rendered for the background of selected items, such as in menus, comboboxes, and text.
static SystemColor textHighlightText
          The color rendered for the text of selected items, such as in menus, comboboxes, and text.
static SystemColor textInactiveText
          The color rendered for the text of inactive items, such as in menus.
static SystemColor textText
          The color rendered for the text of text control objects, such as textfields and comboboxes.
static int TEXT_HIGHLIGHT
          The array index for the java.awt.SystemColor.textHighlight system color.
static int TEXT_HIGHLIGHT_TEXT
          The array index for the java.awt.SystemColor.textHighlightText system color.
static int TEXT_INACTIVE_TEXT
          The array index for the java.awt.SystemColor.textInactiveText system color.
static int TEXT_TEXT
          The array index for the java.awt.SystemColor.textText system color.
static int WINDOW
          The array index for the java.awt.SystemColor.window system color.
static SystemColor window
          The color rendered for the background of interior regions inside windows.
static SystemColor windowBorder
          The color rendered for the border around interior regions inside windows.
static SystemColor windowText
          The color rendered for text of interior regions inside windows.
static int WINDOW_BORDER
          The array index for the java.awt.SystemColor.windowBorder system color.
static int WINDOW_TEXT
          The array index for the java.awt.SystemColor.windowText system color.
 
Fields inherited from class java.awt.Color
black, BLACK, blue, BLUE, cyan, CYAN, darkGray, DARK_GRAY, gray, GRAY, green, GREEN, lightGray, LIGHT_GRAY, magenta, MAGENTA, orange, ORANGE, pink, PINK, red, RED, white, WHITE, yellow, YELLOW
 
Method Summary
 PaintContext

          Creates and returns a PaintContext used to generate a solid color pattern.
 int

          Gets the "current" RGB value representing the symbolic color.
 String

          Returns a string representation of this Color's values.
 
Methods inherited from class java.awt.Color
brighter, createContext, darker, decode, equals, getAlpha, getBlue, getColor, getColor, getColor, getColorComponents, getColorComponents, getColorSpace, getComponents, getComponents, getGreen, getHSBColor, getRed, getRGB, getRGBColorComponents, getRGBComponents, getTransparency, hashCode, HSBtoRGB, RGBtoHSB, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

activeCaption

public static final SystemColor activeCaption
The color rendered for the window-title background of the currently active window.

activeCaptionBorder

public static final SystemColor activeCaptionBorder
The color rendered for the border around the currently active window.

activeCaptionText

public static final SystemColor activeCaptionText
The color rendered for the window-title text of the currently active window.

ACTIVE_CAPTION

public static final int ACTIVE_CAPTION
The array index for the {@link #activeCaption} system color.

ACTIVE_CAPTION_BORDER

public static final int ACTIVE_CAPTION_BORDER
The array index for the {@link #activeCaptionBorder} system color.

ACTIVE_CAPTION_TEXT

public static final int ACTIVE_CAPTION_TEXT
The array index for the {@link #activeCaptionText} system color.

CONTROL

public static final int CONTROL
The array index for the {@link #control} system color.

control

public static final SystemColor control
The color rendered for the background of control panels and control objects, such as pushbuttons.

controlDkShadow

public static final SystemColor controlDkShadow
The color rendered for dark shadow areas on 3D control objects, such as pushbuttons. This color is typically derived from the control background color to provide a 3D effect.

controlHighlight

public static final SystemColor controlHighlight
The color rendered for light areas of 3D control objects, such as pushbuttons. This color is typically derived from the control background color to provide a 3D effect.

controlLtHighlight

public static final SystemColor controlLtHighlight
The color rendered for highlight areas of 3D control objects, such as pushbuttons. This color is typically derived from the control background color to provide a 3D effect.

controlShadow

public static final SystemColor controlShadow
The color rendered for shadow areas of 3D control objects, such as pushbuttons. This color is typically derived from the control background color to provide a 3D effect.

controlText

public static final SystemColor controlText
The color rendered for the text of control panels and control objects, such as pushbuttons.

CONTROL_DK_SHADOW

public static final int CONTROL_DK_SHADOW
The array index for the {@link #controlDkShadow} system color.

CONTROL_HIGHLIGHT

public static final int CONTROL_HIGHLIGHT
The array index for the {@link #controlHighlight} system color.

CONTROL_LT_HIGHLIGHT

public static final int CONTROL_LT_HIGHLIGHT
The array index for the {@link #controlLtHighlight} system color.

CONTROL_SHADOW

public static final int CONTROL_SHADOW
The array index for the {@link #controlShadow} system color.

CONTROL_TEXT

public static final int CONTROL_TEXT
The array index for the {@link #controlText} system color.

DESKTOP

public static final int DESKTOP
The array index for the {@link #desktop} system color.

desktop

public static final SystemColor desktop
The color rendered for the background of the desktop.

inactiveCaption

public static final SystemColor inactiveCaption
The color rendered for the window-title background of inactive windows.

inactiveCaptionBorder

public static final SystemColor inactiveCaptionBorder
The color rendered for the border around inactive windows.

inactiveCaptionText

public static final SystemColor inactiveCaptionText
The color rendered for the window-title text of inactive windows.

INACTIVE_CAPTION

public static final int INACTIVE_CAPTION
The array index for the {@link #inactiveCaption} system color.

INACTIVE_CAPTION_BORDER

public static final int INACTIVE_CAPTION_BORDER
The array index for the {@link #inactiveCaptionBorder} system color.

INACTIVE_CAPTION_TEXT

public static final int INACTIVE_CAPTION_TEXT
The array index for the {@link #inactiveCaptionText} system color.

INFO

public static final int INFO
The array index for the {@link #info} system color.

info

public static final SystemColor info
The color rendered for the background of tooltips or spot help.

infoText

public static final SystemColor infoText
The color rendered for the text of tooltips or spot help.

INFO_TEXT

public static final int INFO_TEXT
The array index for the {@link #infoText} system color.

MENU

public static final int MENU
The array index for the {@link #menu} system color.

menu

public static final SystemColor menu
The color rendered for the background of menus.

menuText

public static final SystemColor menuText
The color rendered for the text of menus.

MENU_TEXT

public static final int MENU_TEXT
The array index for the {@link #menuText} system color.

NUM_COLORS

public static final int NUM_COLORS
The number of system colors in the array.

SCROLLBAR

public static final int SCROLLBAR
The array index for the {@link #scrollbar} system color.

scrollbar

public static final SystemColor scrollbar
The color rendered for the background of scrollbars.

TEXT

public static final int TEXT
The array index for the {@link #text} system color.

text

public static final SystemColor text
The color rendered for the background of text control objects, such as textfields and comboboxes.

textHighlight

public static final SystemColor textHighlight
The color rendered for the background of selected items, such as in menus, comboboxes, and text.

textHighlightText

public static final SystemColor textHighlightText
The color rendered for the text of selected items, such as in menus, comboboxes, and text.

textInactiveText

public static final SystemColor textInactiveText
The color rendered for the text of inactive items, such as in menus.

textText

public static final SystemColor textText
The color rendered for the text of text control objects, such as textfields and comboboxes.

TEXT_HIGHLIGHT

public static final int TEXT_HIGHLIGHT
The array index for the {@link #textHighlight} system color.

TEXT_HIGHLIGHT_TEXT

public static final int TEXT_HIGHLIGHT_TEXT
The array index for the {@link #textHighlightText} system color.

TEXT_INACTIVE_TEXT

public static final int TEXT_INACTIVE_TEXT
The array index for the {@link #textInactiveText} system color.

TEXT_TEXT

public static final int TEXT_TEXT
The array index for the {@link #textText} system color.

WINDOW

public static final int WINDOW
The array index for the {@link #window} system color.

window

public static final SystemColor window
The color rendered for the background of interior regions inside windows.

windowBorder

public static final SystemColor windowBorder
The color rendered for the border around interior regions inside windows.

windowText

public static final SystemColor windowText
The color rendered for text of interior regions inside windows.

WINDOW_BORDER

public static final int WINDOW_BORDER
The array index for the {@link #windowBorder} system color.

WINDOW_TEXT

public static final int WINDOW_TEXT
The array index for the {@link #windowText} system color.
Method Detail

createContext

public PaintContext createContext(ColorModel cm,
                                  Rectangle r,
                                  Rectangle2D r2d,
                                  AffineTransform xform,
                                  RenderingHints hints)
Creates and returns a PaintContext used to generate a solid color pattern. This enables a Color object to be used as an argument to any method requiring an object implementing the Paint interface.

Overrides:
createContext in class Color
Parameters:
cm
r
r2d
xform
hints

getRGB

public int getRGB()
Gets the "current" RGB value representing the symbolic color. (Bits 24-31 are 0xff, 16-23 are red, 8-15 are green, 0-7 are blue).

Overrides:
getRGB in class Color

toString

public String toString()
Returns a string representation of this Color's values. This method is intended to be used only for debugging purposes, and the content and format of the returned string may vary between implementations. The returned string may be empty but may not be null.

Overrides:
toString in class Color
Returns:
a string representation of this Color


This documentation differs from the official API. Jadeite adds extra features to the API including: variable font sizes, constructions examples, placeholders for classes and methods, and auto-generated “See Also” links. Additionally it is missing some items found in standard Javadoc documentation, including: generics type information, “Deprecated” tags and comments, “See Also” links, along with other minor differences. Please send any questions or feedback to bam@cs.cmu.edu.
This page displays the Jadeite version of the documention, which is derived from the offical documentation that contains this copyright notice:
Copyright 2008 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. Also see the documentation redistribution policy.
The official Sun™ documentation can be found here at http://java.sun.com/javase/6/docs/api/.