Package ca.cgjennings.ui.theme
Class UltharTheme
- java.lang.Object
-
- ca.cgjennings.ui.theme.Theme
-
- ca.cgjennings.ui.theme.UltharTheme
-
- Direct Known Subclasses:
DreamlandsTheme
public class UltharTheme extends Theme
A Theme implementation that wraps the FlatLaf.- Since:
- 3.2
- Author:
- Chris Jennings
-
-
Field Summary
-
Fields inherited from class ca.cgjennings.ui.theme.Theme
ALTERNATE_DOCUMENT_TAB_ORIENTATION, CONSOLE_BACKGROUND_PAINTER, CONSOLE_BACKROUND, CONSOLE_ERROR, CONSOLE_FONT, CONSOLE_INFO, CONSOLE_OUTPUT, CONSOLE_SELECTION_BACKGROUND, CONSOLE_SELECTION_FOREGROUND, CONSOLE_WARNING, CONTEXT_BAR_BACKGROUND, CONTEXT_BAR_BUTTON_ARMED_OUTLINE_FOREGROUND, CONTEXT_BAR_BUTTON_BACKGROUND, CONTEXT_BAR_BUTTON_ROLLOVER_BACKGROUND, CONTEXT_BAR_BUTTON_ROLLOVER_OUTLINE_FOREGROUND, CONTEXT_BAR_FOREGROUND, CYCLE_BUTTON_ICON_MARGIN_ADJUSTMENT, DISABLED_ICON_FILTER, EDITOR_TAB_BACKGROUND, FILE_DROP_BORDER, HEAD_BANNER_BACKGROUND, HEAD_BANNER_FOREGROUND, HEADING_BORDER, LINK_LABEL_FOREGROUND, MESSAGE_BACKGROUND, MESSAGE_BORDER_DIALOG, MESSAGE_BORDER_EDGE, MESSAGE_BORDER_EXTERIOR, MESSAGE_BORDER_INFORMATION, MESSAGE_BORDER_MAIN, MESSAGE_FOREGROUND, NOTES_BACKGROUND, NOTES_FOREGROUND, PLUGIN_README_BACKGROUND, PLUGIN_README_FOREGROUND, PREFS_BACKGROUND, PREFS_FOREGROUND, PREFS_HEADING, PROJECT_FIND_BACKGROUND, PROJECT_FIND_FOREGROUND, PROJECT_HEADER_BACKGROUND, PROJECT_HEADER_FOREGROUND, PROJECT_NOTES_TAB_BACKGROUND, SIDEPANEL_TITLE_BACKGROUND, SIDEPANEL_TITLE_FOREGROUND
-
-
Constructor Summary
Constructors Constructor Description UltharTheme()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description javax.swing.LookAndFeelcreateLookAndFeelInstance()Returns an instance of the look and feel for the theme.java.lang.StringgetLookAndFeelClassName()Returns the look and feel class name.java.lang.StringgetThemeGroup()Returns a string that names a group to which the theme belongs.booleanisDark()Returns whether the theme is, on the whole, light-on-dark, similar to OS "dark modes".voidmodifyLookAndFeelDefaults(javax.swing.UIDefaults defaults)This method is called after the look and feel has been instantiated but before it has been installed and allows you to modify the look and feel's default properties.voidmodifyManagerDefaults(javax.swing.UIDefaults defaults)This method is called prior to instantiating the look and feel and allows you to modify the UI manager's default properties.-
Methods inherited from class ca.cgjennings.ui.theme.Theme
applyThemeToColor, applyThemeToColor, applyThemeToImage, findAvailableFontFamily, findAvailableFontFamily, getDisabledIcon, getSyntaxThemeUrl, getThemeDescription, getThemeIcon, getThemeName, modifyLookAndFeel, themeInstalled, toString
-
-
-
-
Method Detail
-
getLookAndFeelClassName
public java.lang.String getLookAndFeelClassName()
Description copied from class:ThemeReturns the look and feel class name. Subclasses may override this to use a custom look and feel.- Overrides:
getLookAndFeelClassNamein classTheme- Returns:
- the name of a
LookAndFeelsubclass
-
createLookAndFeelInstance
public javax.swing.LookAndFeel createLookAndFeelInstance()
Description copied from class:ThemeReturns an instance of the look and feel for the theme. IfTheme.getLookAndFeelClassName()returns null, then the theme installer will call this instead. The base class throws anUnsupportedOperationException. If the class name is null and this returns null, the app will refuse to start.- Overrides:
createLookAndFeelInstancein classTheme- Returns:
- a non-null look-and-feel instance for the theme
-
modifyManagerDefaults
public void modifyManagerDefaults(javax.swing.UIDefaults defaults)
Description copied from class:ThemeThis method is called prior to instantiating the look and feel and allows you to modify the UI manager's default properties.- Specified by:
modifyManagerDefaultsin classTheme- Parameters:
defaults- theUIManagerdefaults
-
modifyLookAndFeelDefaults
public void modifyLookAndFeelDefaults(javax.swing.UIDefaults defaults)
Description copied from class:ThemeThis method is called after the look and feel has been instantiated but before it has been installed and allows you to modify the look and feel's default properties.- Specified by:
modifyLookAndFeelDefaultsin classTheme- Parameters:
defaults- the Look and Feel UI defaults
-
getThemeGroup
public java.lang.String getThemeGroup()
Description copied from class:ThemeReturns a string that names a group to which the theme belongs. Themes that have the same group will be placed together in the list of selectable themes. The base class returns the theme name. Themes that complement each other, such as light and dark variants of the same theme, should return the same group name. It is recommended to use the name of the light theme as the group name for both.- Overrides:
getThemeGroupin classTheme- Returns:
- a non-null string naming the theme's group
-
-