Package ghidra.docking.util
Class DockingWindowsLookAndFeelUtils
java.lang.Object
ghidra.docking.util.DockingWindowsLookAndFeelUtils
A utility class to manage LookAndFeel (LaF) settings.
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic String
Returns the currently installed LaF.Returns all installed LaFs.static boolean
Returns thePreferences
value for whether to use inverted colors when painting.static boolean
Returns true if the given UI object is using the Aqua Look and Feel.static boolean
static boolean
Returns true if 'Nimbus' is the current Look and Feelstatic void
Loads settings fromPreferences
.static void
setLookAndFeel
(String lookAndFeelName) Set the look and feel (LAF) indicated by the string passed in as a parameter.static void
setUseInvertedColors
(boolean useInvertedColors)
-
Field Details
-
LAST_LOOK_AND_FEEL_KEY
Preference name for look and feel for the application.- See Also:
-
USE_INVERTED_COLORS_KEY
Preference name for whether to use inverted colors.- See Also:
-
METAL_LOOK_AND_FEEL
Metal is the non-system, generic Java Look and Feel.- See Also:
-
-
Method Details
-
loadFromPreferences
public static void loadFromPreferences()Loads settings fromPreferences
. -
getUseInvertedColorsPreference
public static boolean getUseInvertedColorsPreference()Returns thePreferences
value for whether to use inverted colors when painting.- Returns:
- the
Preferences
value for whether to use inverted colors when painting.
-
getInstalledLookAndFeelName
Returns the currently installed LaF.- Returns:
- the currently installed LaF.
-
setLookAndFeel
Set the look and feel (LAF) indicated by the string passed in as a parameter. The string value can be either the class name of the LAF, as returned byLookAndFeelInfo.getClassName()
or the name as returned byLookAndFeelInfo.getName()
.Note: to be effective, this call needs to be made before any components have been created and shown.
- Parameters:
lookAndFeelName
- the string indicating which look and feel is desired (see above)
-
getLookAndFeelNames
Returns all installed LaFs. This will vary by OS.- Returns:
- all installed LaFs.
-
setUseInvertedColors
public static void setUseInvertedColors(boolean useInvertedColors) -
isUsingAquaUI
Returns true if the given UI object is using the Aqua Look and Feel.- Parameters:
UI
- the UI to examine.- Returns:
- true if the UI is using Aqua
-
isUsingNimbusUI
public static boolean isUsingNimbusUI()Returns true if 'Nimbus' is the current Look and Feel- Returns:
- true if 'Nimbus' is the current Look and Feel
-
isUsingMotifUI
public static boolean isUsingMotifUI()
-