|
||||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.argouml.ui.LookAndFeelMgr
Controls the look and feel and theme of ArgoUML. LookAndFeelMgr has a "Look and Feel" property which represents the Swing Pluggable Look-and-feel. It also has a "Theme" property which represents a MetalTheme when the Metal look-and-feel is selected.
Field Summary | |
---|---|
private java.lang.String |
_defaultLafClass
The class name of Swing's default look and feel (will be used if the LookAndFeel property is null). |
private static javax.swing.plaf.metal.MetalTheme |
BIG_THEME
|
private static Logger |
cat
|
private static java.lang.String |
DEFAULT_KEY
|
private static javax.swing.plaf.metal.MetalTheme |
DEFAULT_THEME
|
private static javax.swing.plaf.metal.MetalTheme |
HUGE_THEME
|
private static java.lang.String |
METAL_LAF
|
static LookAndFeelMgr |
SINGLETON
Deprecated. in version 0.15.2. Use getInstance() instead. |
private static javax.swing.plaf.metal.MetalTheme[] |
THEMES
|
Constructor Summary | |
---|---|
private |
LookAndFeelMgr()
Creates a new instance of LookAndFeelMgr. |
Method Summary | |
---|---|
java.lang.String[] |
getAvailableLookAndFeelNames()
Returns the display names of the available look and feel choices. |
java.lang.String[] |
getAvailableThemeNames()
Returns the display names of the available theme choices. |
java.lang.String |
getCurrentLookAndFeel()
Returns the string identifier for the current look and feel. |
java.lang.String |
getCurrentLookAndFeelName()
Returns the display name of the current look and feel. |
java.lang.String |
getCurrentTheme()
Returns the string identifier for the current theme. |
java.lang.String |
getCurrentThemeName()
Returns the display name of the current theme. |
static LookAndFeelMgr |
getInstance()
get the single instance of the LookAndFeelMgr |
java.lang.String |
getLookAndFeelFromName(java.lang.String name)
Returns the Look and Feel class name identifier for the specified display name, or null if no such Look and Feel is found. |
private javax.swing.plaf.metal.MetalTheme |
getMetalTheme(java.lang.String themeClass)
Returns the MetalTheme for the specified class name. |
java.awt.Font |
getSmallFont()
|
java.awt.Font |
getStandardFont()
|
java.lang.String |
getThemeFromArg(java.lang.String arg)
Detecting the theme from the command line. |
java.lang.String |
getThemeFromName(java.lang.String name)
Returns the theme class name identifier for the specified display name, or null if no such theme is found. |
void |
initializeLookAndFeel()
Sets the appearance of the UI using the current values of the LookAndFeel and Theme properties. |
boolean |
isThemeCompatibleLookAndFeel(java.lang.String lafClass)
Returns true if the specified look and feel class supports setting different themes. |
void |
printThemeArgs()
Outputs command-line arguments supported by this class. |
void |
setCurrentLookAndFeel(java.lang.String lafClass)
Sets the current look and feel, storing the new value in Configuration. |
void |
setCurrentTheme(java.lang.String themeClass)
Sets the current theme, storing the new value in Configuration. |
private void |
setLookAndFeel(java.lang.String lafClass)
Sets the look and feel in the GUI by calling UIManager.setLookAndFeel(). |
private void |
setTheme(javax.swing.plaf.metal.MetalTheme theme)
Sets the metal theme in the GUI by calling MetalLookAndFeel.setCurrentTheme(). |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final LookAndFeelMgr SINGLETON
private static Logger cat
private static final java.lang.String METAL_LAF
private static final java.lang.String DEFAULT_KEY
private static final javax.swing.plaf.metal.MetalTheme DEFAULT_THEME
private static final javax.swing.plaf.metal.MetalTheme BIG_THEME
private static final javax.swing.plaf.metal.MetalTheme HUGE_THEME
private static final javax.swing.plaf.metal.MetalTheme[] THEMES
private java.lang.String _defaultLafClass
Constructor Detail |
private LookAndFeelMgr()
Method Detail |
public static LookAndFeelMgr getInstance()
public void initializeLookAndFeel()
public java.lang.String getThemeFromArg(java.lang.String arg)
public void printThemeArgs()
public java.lang.String[] getAvailableLookAndFeelNames()
public java.lang.String[] getAvailableThemeNames()
public java.lang.String getLookAndFeelFromName(java.lang.String name)
name
- display name of desired look and feel
public java.lang.String getThemeFromName(java.lang.String name)
name
- display name of desired theme
public boolean isThemeCompatibleLookAndFeel(java.lang.String lafClass)
lafClass
- look and feel class name
public java.lang.String getCurrentLookAndFeel()
public java.lang.String getCurrentLookAndFeelName()
public void setCurrentLookAndFeel(java.lang.String lafClass)
lafClass
- class name of desired look and feelpublic java.lang.String getCurrentTheme()
public java.lang.String getCurrentThemeName()
public void setCurrentTheme(java.lang.String themeClass)
themeClass
- class name of desired themepublic java.awt.Font getStandardFont()
public java.awt.Font getSmallFont()
private void setLookAndFeel(java.lang.String lafClass)
lafClass
- class name of look and feelprivate void setTheme(javax.swing.plaf.metal.MetalTheme theme)
theme
- new MetalTheme to setprivate javax.swing.plaf.metal.MetalTheme getMetalTheme(java.lang.String themeClass)
themeClass
- MetalTheme class name
|
||||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
ArgoUML © 1996-2004 (20040306) | ArgoUML Homepage | ArgoUML Developers' page | ArgoUML Cookbook |