kiwi.ui
Class ColorTheme

java.lang.Object
  |
  +--javax.swing.plaf.metal.MetalTheme
        |
        +--javax.swing.plaf.metal.DefaultMetalTheme
              |
              +--kiwi.ui.ColorTheme

public class ColorTheme
extends javax.swing.plaf.metal.DefaultMetalTheme

A color theme object that can be constructed from a Config object. This allows themes to be read from data files.

Author:
Mark Lindner, PING Software Group

Field Summary
private  javax.swing.plaf.ColorUIResource acceleratorForegroundColor
           
private  javax.swing.plaf.ColorUIResource acceleratorSelectedForegroundColor
           
private  javax.swing.plaf.ColorUIResource black
           
private  javax.swing.plaf.ColorUIResource controlColor
           
private  javax.swing.plaf.ColorUIResource controlDarkShadowColor
           
private  javax.swing.plaf.ColorUIResource controlDisabledColor
           
private  javax.swing.plaf.ColorUIResource controlHighlightColor
           
private  javax.swing.plaf.ColorUIResource controlInfoColor
           
private  javax.swing.plaf.ColorUIResource controlShadowColor
           
private  javax.swing.plaf.ColorUIResource controlTextColor
           
private  javax.swing.plaf.FontUIResource controlTextFont
           
private  javax.swing.plaf.ColorUIResource desktopColor
           
private  javax.swing.plaf.ColorUIResource focusColor
           
private  javax.swing.plaf.ColorUIResource highlightedTextColor
           
private  javax.swing.plaf.ColorUIResource inactiveControlTextColor
           
private  javax.swing.plaf.ColorUIResource inactiveSystemTextColor
           
private  javax.swing.plaf.ColorUIResource menuBackgroundColor
           
private  javax.swing.plaf.ColorUIResource menuDisabledForegroundColor
           
private  javax.swing.plaf.ColorUIResource menuForegroundColor
           
private  javax.swing.plaf.ColorUIResource menuSelectedBackgroundColor
           
private  javax.swing.plaf.ColorUIResource menuSelectedForegroundColor
           
private  javax.swing.plaf.FontUIResource menuTextFont
           
private  java.lang.String name
           
private  javax.swing.plaf.ColorUIResource primary1
           
private  javax.swing.plaf.ColorUIResource primary2
           
private  javax.swing.plaf.ColorUIResource primary3
           
private  javax.swing.plaf.ColorUIResource primaryControlColor
           
private  javax.swing.plaf.ColorUIResource primaryControlDarkShadowColor
           
private  javax.swing.plaf.ColorUIResource primaryControlHighlightColor
           
private  javax.swing.plaf.ColorUIResource primaryControlInfoColor
           
private  javax.swing.plaf.ColorUIResource primaryControlShadowColor
           
private  javax.swing.plaf.ColorUIResource secondary1
           
private  javax.swing.plaf.ColorUIResource secondary2
           
private  javax.swing.plaf.ColorUIResource secondary3
           
private  javax.swing.plaf.ColorUIResource separatorBackgroundColor
           
private  javax.swing.plaf.ColorUIResource separatorForegroundColor
           
private  javax.swing.plaf.FontUIResource subTextFont
           
private  javax.swing.plaf.ColorUIResource systemTextColor
           
private  javax.swing.plaf.FontUIResource systemTextFont
           
private  javax.swing.plaf.ColorUIResource textHighlightColor
           
private  javax.swing.plaf.ColorUIResource userTextColor
           
private  javax.swing.plaf.FontUIResource userTextFont
           
private  javax.swing.plaf.ColorUIResource white
           
private  javax.swing.plaf.ColorUIResource windowBackgroundColor
           
private  javax.swing.plaf.ColorUIResource windowTitleBackgroundColor
           
private  javax.swing.plaf.FontUIResource windowTitleFont
           
private  javax.swing.plaf.ColorUIResource windowTitleForegroundColor
           
private  javax.swing.plaf.ColorUIResource windowTitleInactiveBackgroundColor
           
private  javax.swing.plaf.ColorUIResource windowTitleInactiveForegroundColor
           
 
Fields inherited from class javax.swing.plaf.metal.DefaultMetalTheme
controlFont, smallFont, systemFont, userFont
 
Constructor Summary
ColorTheme(Config config)
          Construct a new ColorTheme.
 
Method Summary
 javax.swing.plaf.ColorUIResource getAcceleratorForeground()
           
 javax.swing.plaf.ColorUIResource getAcceleratorSelectedForeground()
           
protected  javax.swing.plaf.ColorUIResource getBlack()
           
 javax.swing.plaf.ColorUIResource getControl()
           
 javax.swing.plaf.ColorUIResource getControlDarkShadow()
           
 javax.swing.plaf.ColorUIResource getControlDisabled()
           
 javax.swing.plaf.ColorUIResource getControlHighlight()
           
 javax.swing.plaf.ColorUIResource getControlInfo()
           
 javax.swing.plaf.ColorUIResource getControlShadow()
           
 javax.swing.plaf.ColorUIResource getControlTextColor()
           
 javax.swing.plaf.FontUIResource getControlTextFont()
           
 javax.swing.plaf.ColorUIResource getDesktopColor()
           
 javax.swing.plaf.ColorUIResource getFocusColor()
           
 javax.swing.plaf.ColorUIResource getHighlightedTextColor()
           
 javax.swing.plaf.ColorUIResource getInactiveControlTextColor()
           
 javax.swing.plaf.ColorUIResource getInactiveSystemTextColor()
           
 javax.swing.plaf.ColorUIResource getMenuBackground()
           
 javax.swing.plaf.ColorUIResource getMenuDisabledForeground()
           
 javax.swing.plaf.ColorUIResource getMenuForeground()
           
 javax.swing.plaf.ColorUIResource getMenuSelectedBackground()
           
 javax.swing.plaf.ColorUIResource getMenuSelectedForeground()
           
 javax.swing.plaf.FontUIResource getMenuTextFont()
           
 java.lang.String getName()
          Get the name of this color theme.
protected  javax.swing.plaf.ColorUIResource getPrimary1()
           
protected  javax.swing.plaf.ColorUIResource getPrimary2()
           
protected  javax.swing.plaf.ColorUIResource getPrimary3()
           
 javax.swing.plaf.ColorUIResource getPrimaryControl()
           
 javax.swing.plaf.ColorUIResource getPrimaryControlDarkShadow()
           
 javax.swing.plaf.ColorUIResource getPrimaryControlHighlight()
           
 javax.swing.plaf.ColorUIResource getPrimaryControlInfo()
           
 javax.swing.plaf.ColorUIResource getPrimaryControlShadow()
           
protected  javax.swing.plaf.ColorUIResource getSecondary1()
           
protected  javax.swing.plaf.ColorUIResource getSecondary2()
           
protected  javax.swing.plaf.ColorUIResource getSecondary3()
           
 javax.swing.plaf.ColorUIResource getSeparatorBackground()
           
 javax.swing.plaf.ColorUIResource getSeparatorForeground()
           
 javax.swing.plaf.FontUIResource getSubTextFont()
           
 javax.swing.plaf.ColorUIResource getSystemTextColor()
           
 javax.swing.plaf.FontUIResource getSystemTextFont()
           
 javax.swing.plaf.ColorUIResource getTextHighlightColor()
           
 javax.swing.plaf.ColorUIResource getUserTextColor()
           
 javax.swing.plaf.FontUIResource getUserTextFont()
           
protected  javax.swing.plaf.ColorUIResource getWhite()
           
 javax.swing.plaf.ColorUIResource getWindowBackground()
           
 javax.swing.plaf.ColorUIResource getWindowTitleBackground()
           
 javax.swing.plaf.FontUIResource getWindowTitleFont()
           
 javax.swing.plaf.ColorUIResource getWindowTitleForeground()
           
 javax.swing.plaf.ColorUIResource getWindowTitleInactiveBackground()
           
 javax.swing.plaf.ColorUIResource getWindowTitleInactiveForeground()
           
private  void init(Config config)
           
 
Methods inherited from class javax.swing.plaf.metal.MetalTheme
, addCustomEntriesToTable
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

name

private java.lang.String name

primary1

private javax.swing.plaf.ColorUIResource primary1

primary2

private javax.swing.plaf.ColorUIResource primary2

primary3

private javax.swing.plaf.ColorUIResource primary3

secondary1

private javax.swing.plaf.ColorUIResource secondary1

secondary2

private javax.swing.plaf.ColorUIResource secondary2

secondary3

private javax.swing.plaf.ColorUIResource secondary3

black

private javax.swing.plaf.ColorUIResource black

white

private javax.swing.plaf.ColorUIResource white

acceleratorForegroundColor

private javax.swing.plaf.ColorUIResource acceleratorForegroundColor

acceleratorSelectedForegroundColor

private javax.swing.plaf.ColorUIResource acceleratorSelectedForegroundColor

controlColor

private javax.swing.plaf.ColorUIResource controlColor

controlDarkShadowColor

private javax.swing.plaf.ColorUIResource controlDarkShadowColor

controlDisabledColor

private javax.swing.plaf.ColorUIResource controlDisabledColor

controlHighlightColor

private javax.swing.plaf.ColorUIResource controlHighlightColor

controlInfoColor

private javax.swing.plaf.ColorUIResource controlInfoColor

controlShadowColor

private javax.swing.plaf.ColorUIResource controlShadowColor

controlTextColor

private javax.swing.plaf.ColorUIResource controlTextColor

desktopColor

private javax.swing.plaf.ColorUIResource desktopColor

focusColor

private javax.swing.plaf.ColorUIResource focusColor

highlightedTextColor

private javax.swing.plaf.ColorUIResource highlightedTextColor

inactiveControlTextColor

private javax.swing.plaf.ColorUIResource inactiveControlTextColor

inactiveSystemTextColor

private javax.swing.plaf.ColorUIResource inactiveSystemTextColor

menuBackgroundColor

private javax.swing.plaf.ColorUIResource menuBackgroundColor

menuDisabledForegroundColor

private javax.swing.plaf.ColorUIResource menuDisabledForegroundColor

menuForegroundColor

private javax.swing.plaf.ColorUIResource menuForegroundColor

menuSelectedBackgroundColor

private javax.swing.plaf.ColorUIResource menuSelectedBackgroundColor

menuSelectedForegroundColor

private javax.swing.plaf.ColorUIResource menuSelectedForegroundColor

primaryControlColor

private javax.swing.plaf.ColorUIResource primaryControlColor

primaryControlDarkShadowColor

private javax.swing.plaf.ColorUIResource primaryControlDarkShadowColor

primaryControlHighlightColor

private javax.swing.plaf.ColorUIResource primaryControlHighlightColor

primaryControlInfoColor

private javax.swing.plaf.ColorUIResource primaryControlInfoColor

primaryControlShadowColor

private javax.swing.plaf.ColorUIResource primaryControlShadowColor

separatorBackgroundColor

private javax.swing.plaf.ColorUIResource separatorBackgroundColor

separatorForegroundColor

private javax.swing.plaf.ColorUIResource separatorForegroundColor

systemTextColor

private javax.swing.plaf.ColorUIResource systemTextColor

textHighlightColor

private javax.swing.plaf.ColorUIResource textHighlightColor

userTextColor

private javax.swing.plaf.ColorUIResource userTextColor

windowBackgroundColor

private javax.swing.plaf.ColorUIResource windowBackgroundColor

windowTitleBackgroundColor

private javax.swing.plaf.ColorUIResource windowTitleBackgroundColor

windowTitleForegroundColor

private javax.swing.plaf.ColorUIResource windowTitleForegroundColor

windowTitleInactiveBackgroundColor

private javax.swing.plaf.ColorUIResource windowTitleInactiveBackgroundColor

windowTitleInactiveForegroundColor

private javax.swing.plaf.ColorUIResource windowTitleInactiveForegroundColor

controlTextFont

private javax.swing.plaf.FontUIResource controlTextFont

menuTextFont

private javax.swing.plaf.FontUIResource menuTextFont

subTextFont

private javax.swing.plaf.FontUIResource subTextFont

systemTextFont

private javax.swing.plaf.FontUIResource systemTextFont

userTextFont

private javax.swing.plaf.FontUIResource userTextFont

windowTitleFont

private javax.swing.plaf.FontUIResource windowTitleFont
Constructor Detail

ColorTheme

public ColorTheme(Config config)
Construct a new ColorTheme.
Parameters:
config - The Config object from which color and font properties will be read.
Method Detail

getName

public java.lang.String getName()
Get the name of this color theme.
Overrides:
getName in class javax.swing.plaf.metal.DefaultMetalTheme
Returns:
The name of the theme.

getPrimary1

protected javax.swing.plaf.ColorUIResource getPrimary1()
Overrides:
getPrimary1 in class javax.swing.plaf.metal.DefaultMetalTheme

getPrimary2

protected javax.swing.plaf.ColorUIResource getPrimary2()
Overrides:
getPrimary2 in class javax.swing.plaf.metal.DefaultMetalTheme

getPrimary3

protected javax.swing.plaf.ColorUIResource getPrimary3()
Overrides:
getPrimary3 in class javax.swing.plaf.metal.DefaultMetalTheme

getSecondary1

protected javax.swing.plaf.ColorUIResource getSecondary1()
Overrides:
getSecondary1 in class javax.swing.plaf.metal.DefaultMetalTheme

getSecondary2

protected javax.swing.plaf.ColorUIResource getSecondary2()
Overrides:
getSecondary2 in class javax.swing.plaf.metal.DefaultMetalTheme

getSecondary3

protected javax.swing.plaf.ColorUIResource getSecondary3()
Overrides:
getSecondary3 in class javax.swing.plaf.metal.DefaultMetalTheme

getBlack

protected javax.swing.plaf.ColorUIResource getBlack()
Overrides:
getBlack in class javax.swing.plaf.metal.MetalTheme

getWhite

protected javax.swing.plaf.ColorUIResource getWhite()
Overrides:
getWhite in class javax.swing.plaf.metal.MetalTheme

getAcceleratorForeground

public javax.swing.plaf.ColorUIResource getAcceleratorForeground()
Overrides:
getAcceleratorForeground in class javax.swing.plaf.metal.MetalTheme

getAcceleratorSelectedForeground

public javax.swing.plaf.ColorUIResource getAcceleratorSelectedForeground()
Overrides:
getAcceleratorSelectedForeground in class javax.swing.plaf.metal.MetalTheme

getControl

public javax.swing.plaf.ColorUIResource getControl()
Overrides:
getControl in class javax.swing.plaf.metal.MetalTheme

getControlDarkShadow

public javax.swing.plaf.ColorUIResource getControlDarkShadow()
Overrides:
getControlDarkShadow in class javax.swing.plaf.metal.MetalTheme

getControlDisabled

public javax.swing.plaf.ColorUIResource getControlDisabled()
Overrides:
getControlDisabled in class javax.swing.plaf.metal.MetalTheme

getControlHighlight

public javax.swing.plaf.ColorUIResource getControlHighlight()
Overrides:
getControlHighlight in class javax.swing.plaf.metal.MetalTheme

getControlInfo

public javax.swing.plaf.ColorUIResource getControlInfo()
Overrides:
getControlInfo in class javax.swing.plaf.metal.MetalTheme

getControlShadow

public javax.swing.plaf.ColorUIResource getControlShadow()
Overrides:
getControlShadow in class javax.swing.plaf.metal.MetalTheme

getControlTextColor

public javax.swing.plaf.ColorUIResource getControlTextColor()
Overrides:
getControlTextColor in class javax.swing.plaf.metal.MetalTheme

getDesktopColor

public javax.swing.plaf.ColorUIResource getDesktopColor()
Overrides:
getDesktopColor in class javax.swing.plaf.metal.MetalTheme

getFocusColor

public javax.swing.plaf.ColorUIResource getFocusColor()
Overrides:
getFocusColor in class javax.swing.plaf.metal.MetalTheme

getHighlightedTextColor

public javax.swing.plaf.ColorUIResource getHighlightedTextColor()
Overrides:
getHighlightedTextColor in class javax.swing.plaf.metal.MetalTheme

getInactiveControlTextColor

public javax.swing.plaf.ColorUIResource getInactiveControlTextColor()
Overrides:
getInactiveControlTextColor in class javax.swing.plaf.metal.MetalTheme

getInactiveSystemTextColor

public javax.swing.plaf.ColorUIResource getInactiveSystemTextColor()
Overrides:
getInactiveSystemTextColor in class javax.swing.plaf.metal.MetalTheme

getMenuBackground

public javax.swing.plaf.ColorUIResource getMenuBackground()
Overrides:
getMenuBackground in class javax.swing.plaf.metal.MetalTheme

getMenuDisabledForeground

public javax.swing.plaf.ColorUIResource getMenuDisabledForeground()
Overrides:
getMenuDisabledForeground in class javax.swing.plaf.metal.MetalTheme

getMenuForeground

public javax.swing.plaf.ColorUIResource getMenuForeground()
Overrides:
getMenuForeground in class javax.swing.plaf.metal.MetalTheme

getMenuSelectedBackground

public javax.swing.plaf.ColorUIResource getMenuSelectedBackground()
Overrides:
getMenuSelectedBackground in class javax.swing.plaf.metal.MetalTheme

getMenuSelectedForeground

public javax.swing.plaf.ColorUIResource getMenuSelectedForeground()
Overrides:
getMenuSelectedForeground in class javax.swing.plaf.metal.MetalTheme

getPrimaryControl

public javax.swing.plaf.ColorUIResource getPrimaryControl()
Overrides:
getPrimaryControl in class javax.swing.plaf.metal.MetalTheme

getPrimaryControlDarkShadow

public javax.swing.plaf.ColorUIResource getPrimaryControlDarkShadow()
Overrides:
getPrimaryControlDarkShadow in class javax.swing.plaf.metal.MetalTheme

getPrimaryControlHighlight

public javax.swing.plaf.ColorUIResource getPrimaryControlHighlight()
Overrides:
getPrimaryControlHighlight in class javax.swing.plaf.metal.MetalTheme

getPrimaryControlInfo

public javax.swing.plaf.ColorUIResource getPrimaryControlInfo()
Overrides:
getPrimaryControlInfo in class javax.swing.plaf.metal.MetalTheme

getPrimaryControlShadow

public javax.swing.plaf.ColorUIResource getPrimaryControlShadow()
Overrides:
getPrimaryControlShadow in class javax.swing.plaf.metal.MetalTheme

getSeparatorBackground

public javax.swing.plaf.ColorUIResource getSeparatorBackground()
Overrides:
getSeparatorBackground in class javax.swing.plaf.metal.MetalTheme

getSeparatorForeground

public javax.swing.plaf.ColorUIResource getSeparatorForeground()
Overrides:
getSeparatorForeground in class javax.swing.plaf.metal.MetalTheme

getSystemTextColor

public javax.swing.plaf.ColorUIResource getSystemTextColor()
Overrides:
getSystemTextColor in class javax.swing.plaf.metal.MetalTheme

getTextHighlightColor

public javax.swing.plaf.ColorUIResource getTextHighlightColor()
Overrides:
getTextHighlightColor in class javax.swing.plaf.metal.MetalTheme

getUserTextColor

public javax.swing.plaf.ColorUIResource getUserTextColor()
Overrides:
getUserTextColor in class javax.swing.plaf.metal.MetalTheme

getWindowBackground

public javax.swing.plaf.ColorUIResource getWindowBackground()
Overrides:
getWindowBackground in class javax.swing.plaf.metal.MetalTheme

getWindowTitleBackground

public javax.swing.plaf.ColorUIResource getWindowTitleBackground()
Overrides:
getWindowTitleBackground in class javax.swing.plaf.metal.MetalTheme

getWindowTitleForeground

public javax.swing.plaf.ColorUIResource getWindowTitleForeground()
Overrides:
getWindowTitleForeground in class javax.swing.plaf.metal.MetalTheme

getWindowTitleInactiveBackground

public javax.swing.plaf.ColorUIResource getWindowTitleInactiveBackground()
Overrides:
getWindowTitleInactiveBackground in class javax.swing.plaf.metal.MetalTheme

getWindowTitleInactiveForeground

public javax.swing.plaf.ColorUIResource getWindowTitleInactiveForeground()
Overrides:
getWindowTitleInactiveForeground in class javax.swing.plaf.metal.MetalTheme

getControlTextFont

public javax.swing.plaf.FontUIResource getControlTextFont()
Overrides:
getControlTextFont in class javax.swing.plaf.metal.DefaultMetalTheme

getMenuTextFont

public javax.swing.plaf.FontUIResource getMenuTextFont()
Overrides:
getMenuTextFont in class javax.swing.plaf.metal.DefaultMetalTheme

getSubTextFont

public javax.swing.plaf.FontUIResource getSubTextFont()
Overrides:
getSubTextFont in class javax.swing.plaf.metal.DefaultMetalTheme

getSystemTextFont

public javax.swing.plaf.FontUIResource getSystemTextFont()
Overrides:
getSystemTextFont in class javax.swing.plaf.metal.DefaultMetalTheme

getUserTextFont

public javax.swing.plaf.FontUIResource getUserTextFont()
Overrides:
getUserTextFont in class javax.swing.plaf.metal.DefaultMetalTheme

getWindowTitleFont

public javax.swing.plaf.FontUIResource getWindowTitleFont()
Overrides:
getWindowTitleFont in class javax.swing.plaf.metal.DefaultMetalTheme

init

private void init(Config config)