Class NimbusLookAndFeelManager
LookAndFeelManager
. Specialized so that it can return the Nimbus installer and
perform specialized updating when icons or fonts change. Basically, this class needs to
re-install a new instance of the Nimbus LookAndFeel each time a font or icon changes.-
Field Summary
Fields inherited from class generic.theme.laf.LookAndFeelManager
normalizedIdToLafIdMap, themeManager
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected UiDefaultsMapper
createUiDefaultsMapper
(UIDefaults defaults) protected void
Subclasses may override this method to install a specific look and feel.protected void
Subclass may override this method to do specific LookAndFeel fixes.void
fontsChanged
(Set<String> affectedJavaIds) Called when one or more fonts have changed.void
iconsChanged
(Set<String> affectedJavaIds, Icon newIcon) Called when one or more icons have changed.protected void
Extracts java default colors, fonts, and icons and stores them in theThemeManager
and updates theUIDefaults
by installing GColors for all color values and installing any overridden fonts or icons.void
resetAll
(GThemeValueMap javaDefaults) Called when all colors, fonts, and icons may have changedMethods inherited from class generic.theme.laf.LookAndFeelManager
colorsChanged, findLookAndFeelClassName, getLookAndFeelIdsForType, getLookAndFeelType, installCursorBlinkingProperties, installLookAndFeel, isSupported, registerFont, registerFont, repaintAll, setKeyBinding, unRegisterFont, updateAllRegisteredComponentFonts, updateComponentUis
-
Constructor Details
-
NimbusLookAndFeelManager
-
-
Method Details
-
resetAll
Description copied from class:LookAndFeelManager
Called when all colors, fonts, and icons may have changed- Overrides:
resetAll
in classLookAndFeelManager
- Parameters:
javaDefaults
- the current set of java defaults so that those ids can be updated special as needed by the currentLookAndFeel
-
fontsChanged
Description copied from class:LookAndFeelManager
Called when one or more fonts have changed.This will update the Java
UIManager
and trigger a reload of the UIs.- Overrides:
fontsChanged
in classLookAndFeelManager
- Parameters:
affectedJavaIds
- the set of Java Font ids that are affected by this change; these are the normalized ids
-
iconsChanged
Description copied from class:LookAndFeelManager
Called when one or more icons have changed.- Overrides:
iconsChanged
in classLookAndFeelManager
- Parameters:
affectedJavaIds
- set of icon ids affected by this icon changenewIcon
- the new icon to use for the given set of icon ids
-
doInstallLookAndFeel
Description copied from class:LookAndFeelManager
Subclasses may override this method to install a specific look and feel.- Overrides:
doInstallLookAndFeel
in classLookAndFeelManager
- Throws:
UnsupportedLookAndFeelException
- iflnf.isSupportedLookAndFeel()
is false
-
processJavaDefaults
protected void processJavaDefaults()Description copied from class:LookAndFeelManager
Extracts java default colors, fonts, and icons and stores them in theThemeManager
and updates theUIDefaults
by installing GColors for all color values and installing any overridden fonts or icons.- Overrides:
processJavaDefaults
in classLookAndFeelManager
-
fixupLookAndFeelIssues
protected void fixupLookAndFeelIssues()Description copied from class:LookAndFeelManager
Subclass may override this method to do specific LookAndFeel fixes.This will get called after default values are loaded. This means that any values installed by this method will overwrite any values registered by the theme.
Standard properties, such as strings and booleans, can be set inside of the theme properties files. For more complicated UIManager properties, look and feel classes will need to override this method and install those directly.
Any property installed here will not fully be part of the theme system, but rather will be directly installed into the Java Look and Feel. Thus, properties installed here will be hard-coded overrides for the system. If we decided that a hard-coded value should be put into the theme system, then we will need to add support for that property type so that it can be used when loading the theme files.
- Overrides:
fixupLookAndFeelIssues
in classLookAndFeelManager
-
createUiDefaultsMapper
- Specified by:
createUiDefaultsMapper
in classLookAndFeelManager
-