- java.lang.Object
-
- javax.swing.plaf.metal.MetalTheme
-
- javax.swing.plaf.metal.DefaultMetalTheme
-
- javax.swing.plaf.metal.OceanTheme
-
public class OceanTheme extends DefaultMetalTheme
The default theme for theMetalLookAndFeel
.The designers of the Metal Look and Feel strive to keep the default look up to date, possibly through the use of new themes in the future. Therefore, developers should only use this class directly when they wish to customize the "Ocean" look, or force it to be the current theme, regardless of future updates.
All colors returned by
OceanTheme
are completely opaque.- Since:
- 1.5
- See Also:
MetalLookAndFeel.setCurrentTheme(javax.swing.plaf.metal.MetalTheme)
-
-
Constructor Summary
Constructors Constructor and Description OceanTheme()
Creates an instance ofOceanTheme
-
Method Summary
Methods Modifier and Type Method and Description void
addCustomEntriesToTable(UIDefaults table)
Add this theme's custom entries to the defaults table.protected ColorUIResource
getBlack()
Returns the black color.ColorUIResource
getControlTextColor()
Returns the control text color.ColorUIResource
getDesktopColor()
Returns the desktop color.ColorUIResource
getInactiveControlTextColor()
Returns the inactive control text color.ColorUIResource
getMenuDisabledForeground()
Returns the menu disabled foreground color.String
getName()
Return the name of this theme, "Ocean".protected ColorUIResource
getPrimary1()
Returns the primary 1 color.protected ColorUIResource
getPrimary2()
Returns the primary 2 color.protected ColorUIResource
getPrimary3()
Returns the primary 3 color.protected ColorUIResource
getSecondary1()
Returns the secondary 1 color.protected ColorUIResource
getSecondary2()
Returns the secondary 2 color.protected ColorUIResource
getSecondary3()
Returns the secondary 3 color.-
Methods inherited from class javax.swing.plaf.metal.DefaultMetalTheme
getControlTextFont, getMenuTextFont, getSubTextFont, getSystemTextFont, getUserTextFont, getWindowTitleFont
-
Methods inherited from class javax.swing.plaf.metal.MetalTheme
getAcceleratorForeground, getAcceleratorSelectedForeground, getControl, getControlDarkShadow, getControlDisabled, getControlHighlight, getControlInfo, getControlShadow, getFocusColor, getHighlightedTextColor, getInactiveSystemTextColor, getMenuBackground, getMenuForeground, getMenuSelectedBackground, getMenuSelectedForeground, getPrimaryControl, getPrimaryControlDarkShadow, getPrimaryControlHighlight, getPrimaryControlInfo, getPrimaryControlShadow, getSeparatorBackground, getSeparatorForeground, getSystemTextColor, getTextHighlightColor, getUserTextColor, getWhite, getWindowBackground, getWindowTitleBackground, getWindowTitleForeground, getWindowTitleInactiveBackground, getWindowTitleInactiveForeground
-
-
-
-
Method Detail
-
addCustomEntriesToTable
public void addCustomEntriesToTable(UIDefaults table)
Add this theme's custom entries to the defaults table.- Overrides:
addCustomEntriesToTable
in classMetalTheme
- Parameters:
table
- the defaults table, non-null- Throws:
NullPointerException
- iftable
isnull
- See Also:
MetalLookAndFeel.getDefaults()
-
getName
public String getName()
Return the name of this theme, "Ocean".- Overrides:
getName
in classDefaultMetalTheme
- Returns:
- "Ocean"
-
getPrimary1
protected ColorUIResource getPrimary1()
Returns the primary 1 color. This returns a color with an rgb hex value of0x6382BF
.- Overrides:
getPrimary1
in classDefaultMetalTheme
- Returns:
- the primary 1 color
- See Also:
Color.decode(java.lang.String)
-
getPrimary2
protected ColorUIResource getPrimary2()
Returns the primary 2 color. This returns a color with an rgb hex value of0xA3B8CC
.- Overrides:
getPrimary2
in classDefaultMetalTheme
- Returns:
- the primary 2 color
- See Also:
Color.decode(java.lang.String)
-
getPrimary3
protected ColorUIResource getPrimary3()
Returns the primary 3 color. This returns a color with an rgb hex value of0xB8CFE5
.- Overrides:
getPrimary3
in classDefaultMetalTheme
- Returns:
- the primary 3 color
- See Also:
Color.decode(java.lang.String)
-
getSecondary1
protected ColorUIResource getSecondary1()
Returns the secondary 1 color. This returns a color with an rgb hex value of0x7A8A99
.- Overrides:
getSecondary1
in classDefaultMetalTheme
- Returns:
- the secondary 1 color
- See Also:
Color.decode(java.lang.String)
-
getSecondary2
protected ColorUIResource getSecondary2()
Returns the secondary 2 color. This returns a color with an rgb hex value of0xB8CFE5
.- Overrides:
getSecondary2
in classDefaultMetalTheme
- Returns:
- the secondary 2 color
- See Also:
Color.decode(java.lang.String)
-
getSecondary3
protected ColorUIResource getSecondary3()
Returns the secondary 3 color. This returns a color with an rgb hex value of0xEEEEEE
.- Overrides:
getSecondary3
in classDefaultMetalTheme
- Returns:
- the secondary 3 color
- See Also:
Color.decode(java.lang.String)
-
getBlack
protected ColorUIResource getBlack()
Returns the black color. This returns a color with an rgb hex value of0x333333
.- Overrides:
getBlack
in classMetalTheme
- Returns:
- the black color
- See Also:
Color.decode(java.lang.String)
-
getDesktopColor
public ColorUIResource getDesktopColor()
Returns the desktop color. This returns a color with an rgb hex value of0xFFFFFF
.- Overrides:
getDesktopColor
in classMetalTheme
- Returns:
- the desktop color
- See Also:
Color.decode(java.lang.String)
-
getInactiveControlTextColor
public ColorUIResource getInactiveControlTextColor()
Returns the inactive control text color. This returns a color with an rgb hex value of0x999999
.- Overrides:
getInactiveControlTextColor
in classMetalTheme
- Returns:
- the inactive control text color
-
getControlTextColor
public ColorUIResource getControlTextColor()
Returns the control text color. This returns a color with an rgb hex value of0x333333
.- Overrides:
getControlTextColor
in classMetalTheme
- Returns:
- the control text color
-
getMenuDisabledForeground
public ColorUIResource getMenuDisabledForeground()
Returns the menu disabled foreground color. This returns a color with an rgb hex value of0x999999
.- Overrides:
getMenuDisabledForeground
in classMetalTheme
- Returns:
- the menu disabled foreground color
-
-
Traduction non disponible
Les API Java ne sont pas encore traduites en français sur l'infobrol. Seule la version anglaise est disponible pour l'instant.
Version en cache
28/12/2024 07:33:35 Cette version de la page est en cache (à la date du 28/12/2024 07:33:35) afin d'accélérer le traitement. Vous pouvez activer le mode utilisateur dans le menu en haut pour afficher la dernère version de la page.Document créé le 30/08/2006, dernière modification le 04/03/2020
Source du document imprimé : https://www.gaudry.be/java-api-rf-javax/swing/plaf/metal/OceanTheme.html
L'infobrol est un site personnel dont le contenu n'engage que moi. Le texte est mis à disposition sous licence CreativeCommons(BY-NC-SA). Plus d'info sur les conditions d'utilisation et sur l'auteur.
Références
Ces références et liens indiquent des documents consultés lors de la rédaction de cette page, ou qui peuvent apporter un complément d'information, mais les auteurs de ces sources ne peuvent être tenus responsables du contenu de cette page.
L'auteur de ce site est seul responsable de la manière dont sont présentés ici les différents concepts, et des libertés qui sont prises avec les ouvrages de référence. N'oubliez pas que vous devez croiser les informations de sources multiples afin de diminuer les risques d'erreurs.