Quaqua 5.4.1 2009-07-14

ch.randelshofer.quaqua
Class BasicQuaquaLookAndFeel

java.lang.Object
  extended by javax.swing.LookAndFeel
      extended by javax.swing.plaf.basic.BasicLookAndFeel
          extended by ch.randelshofer.quaqua.LookAndFeelProxy
              extended by ch.randelshofer.quaqua.BasicQuaquaLookAndFeel
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
Quaqua14JaguarLookAndFeel, Quaqua14LeopardLookAndFeel, Quaqua14PantherLookAndFeel, Quaqua14TigerLookAndFeel, Quaqua15JaguarLookAndFeel, Quaqua15LeopardLookAndFeel, Quaqua15PantherLookAndFeel, Quaqua15TigerLookAndFeel

public class BasicQuaquaLookAndFeel
extends LookAndFeelProxy

The BasicQuaquaLookAndFeel contains the look and feel properties that are commonly uses by all the specific QuaquaLookAndFeel incarnations.

Version:
$Id: BasicQuaquaLookAndFeel.java 96 2009-06-27 07:47:23Z wrandelshofer $
Author:
Werner Randelshofer
See Also:
Serialized Form

Field Summary
protected static java.lang.String commonDir
           
protected static java.lang.String jaguarDir
           
protected static java.lang.String leopardDir
           
protected static java.lang.String pantherDir
           
protected static java.lang.String tigerDir
           
 
Fields inherited from class ch.randelshofer.quaqua.LookAndFeelProxy
target
 
Constructor Summary
BasicQuaquaLookAndFeel(java.lang.String targetClassName)
          Creates a new instance.
 
Method Summary
protected  java.awt.Font getBaseSystemFont()
          Returns the base font for which system fonts are derived.
 javax.swing.UIDefaults getDefaults()
          This method is called once by UIManager.setLookAndFeel to create the look and feel specific defaults table.
 java.lang.String getID()
          Return a string that identifies this look and feel.
 boolean getSupportsWindowDecorations()
          Returns true if the LookAndFeel returned RootPaneUI instances support providing Window decorations in a JRootPane.
protected  void initColorDefaults(javax.swing.UIDefaults table)
           
protected  void initComponentDefaults(javax.swing.UIDefaults table)
           
protected  void initDesignDefaults(javax.swing.UIDefaults table)
          Init design specific look and feel defaults.
protected  void initFontDefaults(javax.swing.UIDefaults table)
           
protected  void initGeneralDefaults(javax.swing.UIDefaults table)
          The defaults initialized here are common to all Quaqua Look and Feels.
protected  void initInputMapDefaults(javax.swing.UIDefaults table)
           
protected  void initResourceBundle(javax.swing.UIDefaults table)
           
protected  void initSystemColorDefaults(javax.swing.UIDefaults table)
          Load the SystemColors into the defaults table.
protected  void installKeyboardFocusManager()
           
protected  boolean isJaguarTabbedPane()
           
protected  java.lang.Object makeBufferedImage(java.lang.String location)
           
protected static java.lang.Object makeButtonStateIcon(java.lang.String location, int states)
           
protected static java.lang.Object makeButtonStateIcon(java.lang.String location, int states, java.awt.Point shift)
           
protected static java.lang.Object makeButtonStateIcon(java.lang.String location, int states, java.awt.Rectangle shift)
           
protected static java.lang.Object makeFrameButtonStateIcon(java.lang.String location, int states)
           
static java.lang.Object makeIcon(java.lang.Class baseClass, java.lang.String location)
           
static java.lang.Object makeIcon(java.lang.Class baseClass, java.lang.String location, java.awt.Point shift)
           
static java.lang.Object makeIcon(java.lang.Class baseClass, java.lang.String location, java.awt.Rectangle shiftAndSize)
           
protected static java.lang.Object makeIcons(java.lang.String location, int states, boolean horizontal)
           
protected  java.lang.Object makeImage(java.lang.String location)
           
protected  java.lang.Object makeImageBevelBackgroundBorder(java.lang.String location, java.awt.Insets imageInsets, java.awt.Insets borderInsets, boolean fill)
           
protected  java.lang.Object makeImageBevelBorder(java.lang.String location, java.awt.Insets insets)
           
protected  java.lang.Object makeImageBevelBorder(java.lang.String location, java.awt.Insets insets, boolean fill)
           
protected  java.lang.Object makeImageBevelBorder(java.lang.String location, java.awt.Insets imageInsets, java.awt.Insets borderInsets, boolean fill)
           
protected  java.lang.Object makeImageBevelBorders(java.lang.String location, java.awt.Insets insets, int states, boolean horizontal)
           
static java.lang.Object makeNativeIcon(java.lang.String path, int size)
           
static java.lang.Object makeNativeIcon(java.lang.String path, int width, int height)
           
protected  java.lang.Object makeOverlaidButtonStateIcon(java.lang.String location1, int states1, java.lang.String location2, int states2, java.awt.Rectangle layoutRect)
           
protected static java.lang.Object makeSliderThumbIcon(java.lang.String location)
           
protected  java.lang.Object makeTextureColor(int rgb, java.lang.String location)
           
protected  void putDefaults(javax.swing.UIDefaults table, java.lang.Object[] keyValueList)
          Puts defaults into the specified UIDefaults table.
 
Methods inherited from class ch.randelshofer.quaqua.LookAndFeelProxy
getDescription, getName, initialize, isNativeLookAndFeel, isSupportedLookAndFeel, provideErrorFeedback, setTarget, toString, uninitialize
 
Methods inherited from class javax.swing.plaf.basic.BasicLookAndFeel
createAudioAction, getAudioActionMap, initClassDefaults, loadSystemColors, playSound
 
Methods inherited from class javax.swing.LookAndFeel
getDesktopPropertyValue, getDisabledIcon, getDisabledSelectedIcon, installBorder, installColors, installColorsAndFont, installProperty, loadKeyBindings, makeComponentInputMap, makeIcon, makeInputMap, makeKeyBindings, uninstallBorder
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

commonDir

protected static final java.lang.String commonDir
See Also:
Constant Field Values

jaguarDir

protected static final java.lang.String jaguarDir
See Also:
Constant Field Values

pantherDir

protected static final java.lang.String pantherDir
See Also:
Constant Field Values

tigerDir

protected static final java.lang.String tigerDir
See Also:
Constant Field Values

leopardDir

protected static final java.lang.String leopardDir
See Also:
Constant Field Values
Constructor Detail

BasicQuaquaLookAndFeel

public BasicQuaquaLookAndFeel(java.lang.String targetClassName)
Creates a new instance.

Method Detail

getID

public java.lang.String getID()
Return a string that identifies this look and feel. This string will be used by applications/services that want to recognize well known look and feel implementations. Presently the well known names are "Motif", "Windows", "Mac", "Metal". Note that a LookAndFeel derived from a well known superclass that doesn't make any fundamental changes to the look or feel shouldn't override this method.

Overrides:
getID in class LookAndFeelProxy

getDefaults

public javax.swing.UIDefaults getDefaults()
This method is called once by UIManager.setLookAndFeel to create the look and feel specific defaults table. Other applications, for example an application builder, may also call this method.

Overrides:
getDefaults in class LookAndFeelProxy
See Also:
LookAndFeelProxy.initialize(), LookAndFeelProxy.uninitialize(), UIManager.setLookAndFeel(javax.swing.LookAndFeel)

initComponentDefaults

protected final void initComponentDefaults(javax.swing.UIDefaults table)
Overrides:
initComponentDefaults in class javax.swing.plaf.basic.BasicLookAndFeel

initResourceBundle

protected void initResourceBundle(javax.swing.UIDefaults table)

initSystemColorDefaults

protected void initSystemColorDefaults(javax.swing.UIDefaults table)
Load the SystemColors into the defaults table. The keys for SystemColor defaults are the same as the names of the public fields in SystemColor. If the table is being created on a native Windows platform we use the SystemColor values, otherwise we create color uiDefaults whose values match the defaults Windows95 colors.

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

initColorDefaults

protected void initColorDefaults(javax.swing.UIDefaults table)

initInputMapDefaults

protected void initInputMapDefaults(javax.swing.UIDefaults table)

getBaseSystemFont

protected java.awt.Font getBaseSystemFont()
Returns the base font for which system fonts are derived. This is Lucida Grande, Plain, 13.


initFontDefaults

protected void initFontDefaults(javax.swing.UIDefaults table)

initGeneralDefaults

protected void initGeneralDefaults(javax.swing.UIDefaults table)
The defaults initialized here are common to all Quaqua Look and Feels.


makeImage

protected java.lang.Object makeImage(java.lang.String location)

makeBufferedImage

protected java.lang.Object makeBufferedImage(java.lang.String location)

makeIcon

public static java.lang.Object makeIcon(java.lang.Class baseClass,
                                        java.lang.String location)

makeIcon

public static java.lang.Object makeIcon(java.lang.Class baseClass,
                                        java.lang.String location,
                                        java.awt.Point shift)

makeIcon

public static java.lang.Object makeIcon(java.lang.Class baseClass,
                                        java.lang.String location,
                                        java.awt.Rectangle shiftAndSize)

makeIcons

protected static java.lang.Object makeIcons(java.lang.String location,
                                            int states,
                                            boolean horizontal)

makeNativeIcon

public static java.lang.Object makeNativeIcon(java.lang.String path,
                                              int size)

makeNativeIcon

public static java.lang.Object makeNativeIcon(java.lang.String path,
                                              int width,
                                              int height)

makeButtonStateIcon

protected static java.lang.Object makeButtonStateIcon(java.lang.String location,
                                                      int states)

makeButtonStateIcon

protected static java.lang.Object makeButtonStateIcon(java.lang.String location,
                                                      int states,
                                                      java.awt.Point shift)

makeButtonStateIcon

protected static java.lang.Object makeButtonStateIcon(java.lang.String location,
                                                      int states,
                                                      java.awt.Rectangle shift)

makeFrameButtonStateIcon

protected static java.lang.Object makeFrameButtonStateIcon(java.lang.String location,
                                                           int states)

makeSliderThumbIcon

protected static java.lang.Object makeSliderThumbIcon(java.lang.String location)

makeOverlaidButtonStateIcon

protected java.lang.Object makeOverlaidButtonStateIcon(java.lang.String location1,
                                                       int states1,
                                                       java.lang.String location2,
                                                       int states2,
                                                       java.awt.Rectangle layoutRect)

makeImageBevelBorder

protected java.lang.Object makeImageBevelBorder(java.lang.String location,
                                                java.awt.Insets insets)

makeImageBevelBorder

protected java.lang.Object makeImageBevelBorder(java.lang.String location,
                                                java.awt.Insets insets,
                                                boolean fill)

makeImageBevelBorder

protected java.lang.Object makeImageBevelBorder(java.lang.String location,
                                                java.awt.Insets imageInsets,
                                                java.awt.Insets borderInsets,
                                                boolean fill)

makeImageBevelBackgroundBorder

protected java.lang.Object makeImageBevelBackgroundBorder(java.lang.String location,
                                                          java.awt.Insets imageInsets,
                                                          java.awt.Insets borderInsets,
                                                          boolean fill)

makeImageBevelBorders

protected java.lang.Object makeImageBevelBorders(java.lang.String location,
                                                 java.awt.Insets insets,
                                                 int states,
                                                 boolean horizontal)

makeTextureColor

protected java.lang.Object makeTextureColor(int rgb,
                                            java.lang.String location)

initDesignDefaults

protected void initDesignDefaults(javax.swing.UIDefaults table)
Init design specific look and feel defaults.


getSupportsWindowDecorations

public boolean getSupportsWindowDecorations()
Returns true if the LookAndFeel returned RootPaneUI instances support providing Window decorations in a JRootPane.

This implementation returns true, since it does support providing these border and window title pane decorations.

Overrides:
getSupportsWindowDecorations in class LookAndFeelProxy
Returns:
True if the RootPaneUI instances created support client side decorations
Since:
1.4
See Also:
JDialog.setDefaultLookAndFeelDecorated(boolean), JFrame.setDefaultLookAndFeelDecorated(boolean), JRootPane.setWindowDecorationStyle(int)

isJaguarTabbedPane

protected boolean isJaguarTabbedPane()

installKeyboardFocusManager

protected void installKeyboardFocusManager()

putDefaults

protected void putDefaults(javax.swing.UIDefaults table,
                           java.lang.Object[] keyValueList)
Puts defaults into the specified UIDefaults table. Honors QuaquaManager.getIncludedUIs() and QuaquaManager.getExcludedUIs().

Parameters:
table -
keyValueList -

Copyright 2003-2007 (c) Werner Randelshofer.
All rights reserved.