de.muntjak.tinylookandfeel
Class TinyLookAndFeel

java.lang.Object
  extended by javax.swing.LookAndFeel
      extended by javax.swing.plaf.basic.BasicLookAndFeel
          extended by javax.swing.plaf.metal.MetalLookAndFeel
              extended by de.muntjak.tinylookandfeel.TinyLookAndFeel
All Implemented Interfaces:
java.io.Serializable

public class TinyLookAndFeel
extends javax.swing.plaf.metal.MetalLookAndFeel

The Tiny Look and Feel implementation.

See Also:
Serialized Form

Field Summary
static boolean controlPanelInstantiated
          Signals if we are run from the ControlPanel.
static java.lang.String DATE_STRING
          The release date of this TinyLaF release as a string.
static boolean PRINT_CACHE_SIZES
          If true, each drawing cache reports its size as new entries are added.
static java.awt.Robot ROBOT
          A global Robot instance used for the ControlPanel magnifier, to antialias frame caption edges and to capture backgrounds for popup menu shadows.
static java.lang.String VERSION_STRING
          The current TinyLaF version as a string.
 
Constructor Summary
TinyLookAndFeel()
           
 
Method Summary
static void clearAllCaches()
          Clears all caches used to speed up drawing of components.
protected  void createDefaultTheme()
          Creates the default theme and installs it.
 java.lang.String getDescription()
          Returns "TinyLookAndFeel".
 java.lang.String getID()
          Returns "TinyLookAndFeel".
 java.lang.String getName()
          Returns "TinyLookAndFeel".
 boolean getSupportsWindowDecorations()
          Returns true.
static java.lang.String getSystemIconName(int index)
          This method is not intended for public use.
static javax.swing.Icon getUncolorizedSystemIcon(int index)
          This method is not intended for public use.
protected  void initClassDefaults(javax.swing.UIDefaults table)
          Initializes the uiClassID to BasicComponentUI mapping.
protected  void initComponentDefaults(javax.swing.UIDefaults table)
          Initializes the default values for many ui widgets and puts them in the given ui defaults table.
 void initialize()
          Initializes the look and feel.
 boolean isNativeLookAndFeel()
          Returns false.
 boolean isSupportedLookAndFeel()
          Returns true.
static javax.swing.ImageIcon loadIcon(java.lang.String fileName)
          This method is not intended for public use.
 void uninitialize()
          Uninitializes the look and feel.
 
Methods inherited from class javax.swing.plaf.metal.MetalLookAndFeel
getAcceleratorForeground, getAcceleratorSelectedForeground, getBlack, getControl, getControlDarkShadow, getControlDisabled, getControlHighlight, getControlInfo, getControlShadow, getControlTextColor, getControlTextFont, getCurrentTheme, getDefaults, getDesktopColor, getDisabledIcon, getDisabledSelectedIcon, getFocusColor, getHighlightedTextColor, getInactiveControlTextColor, getInactiveSystemTextColor, getLayoutStyle, getMenuBackground, getMenuDisabledForeground, getMenuForeground, getMenuSelectedBackground, getMenuSelectedForeground, getMenuTextFont, getPrimaryControl, getPrimaryControlDarkShadow, getPrimaryControlHighlight, getPrimaryControlInfo, getPrimaryControlShadow, getSeparatorBackground, getSeparatorForeground, getSubTextFont, getSystemTextColor, getSystemTextFont, getTextHighlightColor, getUserTextColor, getUserTextFont, getWhite, getWindowBackground, getWindowTitleBackground, getWindowTitleFont, getWindowTitleForeground, getWindowTitleInactiveBackground, getWindowTitleInactiveForeground, initSystemColorDefaults, provideErrorFeedback, setCurrentTheme
 
Methods inherited from class javax.swing.plaf.basic.BasicLookAndFeel
createAudioAction, getAudioActionMap, loadSystemColors, playSound
 
Methods inherited from class javax.swing.LookAndFeel
getDesktopPropertyValue, installBorder, installColors, installColorsAndFont, installProperty, loadKeyBindings, makeComponentInputMap, makeIcon, makeInputMap, makeKeyBindings, toString, uninstallBorder
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

controlPanelInstantiated

public static boolean controlPanelInstantiated
Signals if we are run from the ControlPanel.


PRINT_CACHE_SIZES

public static final boolean PRINT_CACHE_SIZES
If true, each drawing cache reports its size as new entries are added. Should be false for production build.

See Also:
Constant Field Values

VERSION_STRING

public static final java.lang.String VERSION_STRING
The current TinyLaF version as a string.

See Also:
Constant Field Values

DATE_STRING

public static final java.lang.String DATE_STRING
The release date of this TinyLaF release as a string.

See Also:
Constant Field Values

ROBOT

public static java.awt.Robot ROBOT
A global Robot instance used for the ControlPanel magnifier, to antialias frame caption edges and to capture backgrounds for popup menu shadows.

Constructor Detail

TinyLookAndFeel

public TinyLookAndFeel()
Method Detail

initialize

public void initialize()
Initializes the look and feel.

Overrides:
initialize in class javax.swing.plaf.basic.BasicLookAndFeel

clearAllCaches

public static void clearAllCaches()
Clears all caches used to speed up drawing of components. This method is called automatically if new themes are loaded.


uninitialize

public void uninitialize()
Uninitializes the look and feel.

Overrides:
uninitialize in class javax.swing.plaf.basic.BasicLookAndFeel

getID

public java.lang.String getID()
Returns "TinyLookAndFeel".

Overrides:
getID in class javax.swing.plaf.metal.MetalLookAndFeel
Returns:
"TinyLookAndFeel".

getName

public java.lang.String getName()
Returns "TinyLookAndFeel".

Overrides:
getName in class javax.swing.plaf.metal.MetalLookAndFeel
Returns:
"TinyLookAndFeel".

getDescription

public java.lang.String getDescription()
Returns "TinyLookAndFeel".

Overrides:
getDescription in class javax.swing.plaf.metal.MetalLookAndFeel
Returns:
"TinyLookAndFeel"

isNativeLookAndFeel

public boolean isNativeLookAndFeel()
Returns false.

Overrides:
isNativeLookAndFeel in class javax.swing.plaf.metal.MetalLookAndFeel
Returns:
false

isSupportedLookAndFeel

public final boolean isSupportedLookAndFeel()
Returns true.

Overrides:
isSupportedLookAndFeel in class javax.swing.plaf.metal.MetalLookAndFeel
Returns:
true

getSupportsWindowDecorations

public boolean getSupportsWindowDecorations()
Returns true.

Overrides:
getSupportsWindowDecorations in class javax.swing.plaf.metal.MetalLookAndFeel
Returns:
true

initClassDefaults

protected void initClassDefaults(javax.swing.UIDefaults table)
Initializes the uiClassID to BasicComponentUI mapping. The JComponent classes define their own uiClassID constants. This table must map those constants to a BasicComponentUI class of the appropriate type.

Overrides:
initClassDefaults in class javax.swing.plaf.metal.MetalLookAndFeel
Parameters:
table - The ui defaults table.

createDefaultTheme

protected void createDefaultTheme()
Creates the default theme and installs it. The TinyDefaultTheme is used as default.

Overrides:
createDefaultTheme in class javax.swing.plaf.metal.MetalLookAndFeel

initComponentDefaults

protected void initComponentDefaults(javax.swing.UIDefaults table)
Initializes the default values for many ui widgets and puts them in the given ui defaults table. Here is the place where borders can be changed.

Overrides:
initComponentDefaults in class javax.swing.plaf.metal.MetalLookAndFeel
Parameters:
table - The ui defaults table.

getUncolorizedSystemIcon

public static javax.swing.Icon getUncolorizedSystemIcon(int index)
This method is not intended for public use.

Parameters:
index -
Returns:
an icon

getSystemIconName

public static java.lang.String getSystemIconName(int index)
This method is not intended for public use.

Parameters:
index -
Returns:
the name of a system icon, for example "Tree.closedIcon"

loadIcon

public static javax.swing.ImageIcon loadIcon(java.lang.String fileName)
This method is not intended for public use.

Parameters:
fileName - The icon's file name.
Returns:
the specified icon or null if the icon resource doesn't exist.