Class BladeColorScheme
- java.lang.Object
-
- org.pushingpixels.radiance.theming.internal.blade.BladeColorScheme
-
- All Implemented Interfaces:
RadianceColorScheme
,SchemeBaseColors
,SchemeDerivedColors
,RadianceTrait
public class BladeColorScheme extends java.lang.Object implements RadianceColorScheme
-
-
Field Summary
Fields Modifier and Type Field Description java.awt.Color
accentedBackgroundFill
java.awt.Color
backgroundFill
java.awt.Color
dark
java.lang.String
displayName
java.awt.Color
echo
java.awt.Color
extraLight
java.awt.Color
focusRing
java.awt.Color
foreground
boolean
isDark
java.awt.Color
light
java.awt.Color
line
java.awt.Color
mark
java.awt.Color
mid
java.awt.Color
selectionBackground
java.awt.Color
selectionForeground
java.awt.Color
separatorPrimary
java.awt.Color
separatorSecondary
java.awt.Color
textBackgroundFill
java.awt.Color
ultraDark
java.awt.Color
ultraLight
-
Constructor Summary
Constructors Constructor Description BladeColorScheme()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RadianceColorScheme
blendWith(RadianceColorScheme otherScheme, double likenessToThisScheme)
Creates a blended version ofthis
color scheme based on another color scheme.java.awt.Color
getAccentedBackgroundFillColor()
Returns the accented background fill color forthis
scheme.java.awt.Color
getBackgroundFillColor()
Returns the background fill color forthis
scheme.java.awt.Color
getDarkColor()
Retrieves the dark color.java.lang.String
getDisplayName()
Returns the display name ofthis
trait.java.awt.Color
getEchoColor()
Returns the echo color forthis
scheme.java.awt.Color
getExtraLightColor()
Retrieves the extra color.java.awt.Color
getFocusRingColor()
Returns the focus ring color forthis
scheme.java.awt.Color
getForegroundColor()
Retrieves the foreground color.java.awt.Color
getLightColor()
Retrieves the light color.java.awt.Color
getLineColor()
Returns the line color forthis
scheme.java.awt.Color
getMarkColor()
Returns the mark color forthis
scheme.java.awt.Color
getMidColor()
Retrieves the medium color.java.awt.Color
getSelectionBackgroundColor()
Returns the selection background color forthis
scheme.java.awt.Color
getSelectionForegroundColor()
Returns the selection foreground color forthis
scheme.java.awt.Color
getSeparatorPrimaryColor()
Returns the primary separator color forthis
scheme.java.awt.Color
getSeparatorSecondaryColor()
Returns the secondary separator color forthis
scheme.java.awt.Color
getTextBackgroundFillColor()
Returns the text background fill color forthis
scheme.java.awt.Color
getUltraDarkColor()
Retrieves the ultra-dark color.java.awt.Color
getUltraLightColor()
Retrieves the ultra-light color.RadianceColorScheme
hueShift(double hueShiftFactor)
Creates a hue-shifted (in HSB space) version ofthis
color scheme.RadianceColorScheme
invert()
Creates an inverted version ofthis
scheme.boolean
isDark()
Returns indication whether this color scheme uses dark colors.RadianceColorScheme
named(java.lang.String colorSchemeDisplayName)
This method is a fluent-interface builder utility for setting the display name for this color scheme.RadianceColorScheme
negate()
Creates a negated version ofthis
scheme.RadianceColorScheme
saturate(double saturateFactor)
Creates a saturated or desaturated version ofthis
scheme.RadianceColorScheme
shade(double shadeFactor)
Creates a shaded (shifted towards black) version ofthis
color scheme.RadianceColorScheme
shift(java.awt.Color backgroundShiftColor, double backgroundShiftFactor, java.awt.Color foregroundShiftColor, double foregroundShiftFactor)
Creates a shift version ofthis
scheme.RadianceColorScheme
shiftBackground(java.awt.Color backgroundShiftColor, double backgroundShiftFactor)
Creates a shift version ofthis
scheme.RadianceColorScheme
tint(double tintFactor)
Creates a tinted (shifted towards white) version ofthis
color scheme.RadianceColorScheme
tone(double toneFactor)
Creates a toned (shifted towards gray) version ofthis
color scheme.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.pushingpixels.radiance.theming.api.colorscheme.RadianceColorScheme
getColorFilter
-
Methods inherited from interface org.pushingpixels.radiance.theming.api.colorscheme.SchemeBaseColors
toImage
-
-
-
-
Field Detail
-
displayName
public java.lang.String displayName
-
isDark
public boolean isDark
-
ultraLight
public java.awt.Color ultraLight
-
extraLight
public java.awt.Color extraLight
-
light
public java.awt.Color light
-
mid
public java.awt.Color mid
-
dark
public java.awt.Color dark
-
ultraDark
public java.awt.Color ultraDark
-
foreground
public java.awt.Color foreground
-
backgroundFill
public java.awt.Color backgroundFill
-
accentedBackgroundFill
public java.awt.Color accentedBackgroundFill
-
focusRing
public java.awt.Color focusRing
-
line
public java.awt.Color line
-
selectionForeground
public java.awt.Color selectionForeground
-
selectionBackground
public java.awt.Color selectionBackground
-
textBackgroundFill
public java.awt.Color textBackgroundFill
-
separatorPrimary
public java.awt.Color separatorPrimary
-
separatorSecondary
public java.awt.Color separatorSecondary
-
mark
public java.awt.Color mark
-
echo
public java.awt.Color echo
-
-
Method Detail
-
getDisplayName
public java.lang.String getDisplayName()
Description copied from interface:RadianceTrait
Returns the display name ofthis
trait. This method is part of officially supported API.- Specified by:
getDisplayName
in interfaceRadianceTrait
- Returns:
- The display name of
this
trait.
-
isDark
public boolean isDark()
Description copied from interface:RadianceColorScheme
Returns indication whether this color scheme uses dark colors. Note that this method may be removed in the future. It is highly recommended to use one of the colors from the parentSchemeBaseColors
andSchemeDerivedColors
interfaces instead.- Specified by:
isDark
in interfaceRadianceColorScheme
- Returns:
true
if this color scheme uses dark colors,false
otherwise.
-
getForegroundColor
public java.awt.Color getForegroundColor()
Description copied from interface:SchemeBaseColors
Retrieves the foreground color.- Specified by:
getForegroundColor
in interfaceSchemeBaseColors
- Returns:
- Foreground color.
-
getUltraLightColor
public java.awt.Color getUltraLightColor()
Description copied from interface:SchemeBaseColors
Retrieves the ultra-light color.- Specified by:
getUltraLightColor
in interfaceSchemeBaseColors
- Returns:
- Ultra-light color.
-
getExtraLightColor
public java.awt.Color getExtraLightColor()
Description copied from interface:SchemeBaseColors
Retrieves the extra color.- Specified by:
getExtraLightColor
in interfaceSchemeBaseColors
- Returns:
- Extra color.
-
getLightColor
public java.awt.Color getLightColor()
Description copied from interface:SchemeBaseColors
Retrieves the light color.- Specified by:
getLightColor
in interfaceSchemeBaseColors
- Returns:
- Light color.
-
getMidColor
public java.awt.Color getMidColor()
Description copied from interface:SchemeBaseColors
Retrieves the medium color.- Specified by:
getMidColor
in interfaceSchemeBaseColors
- Returns:
- Medium color.
-
getDarkColor
public java.awt.Color getDarkColor()
Description copied from interface:SchemeBaseColors
Retrieves the dark color.- Specified by:
getDarkColor
in interfaceSchemeBaseColors
- Returns:
- Dark color.
-
getUltraDarkColor
public java.awt.Color getUltraDarkColor()
Description copied from interface:SchemeBaseColors
Retrieves the ultra-dark color.- Specified by:
getUltraDarkColor
in interfaceSchemeBaseColors
- Returns:
- Ultra-dark color.
-
getLineColor
public java.awt.Color getLineColor()
Description copied from interface:SchemeDerivedColors
Returns the line color forthis
scheme.- Specified by:
getLineColor
in interfaceSchemeDerivedColors
- Returns:
- The line color for
this
scheme. - See Also:
RadianceSkin.getOverlayColor(RadianceThemingSlices.ColorOverlayType, RadianceThemingSlices.DecorationAreaType, ComponentState)
-
getSelectionBackgroundColor
public java.awt.Color getSelectionBackgroundColor()
Description copied from interface:SchemeDerivedColors
Returns the selection background color forthis
scheme.- Specified by:
getSelectionBackgroundColor
in interfaceSchemeDerivedColors
- Returns:
- The selection background color for
this
scheme.
-
getSelectionForegroundColor
public java.awt.Color getSelectionForegroundColor()
Description copied from interface:SchemeDerivedColors
Returns the selection foreground color forthis
scheme.- Specified by:
getSelectionForegroundColor
in interfaceSchemeDerivedColors
- Returns:
- The selection foreground color for
this
scheme.
-
getBackgroundFillColor
public java.awt.Color getBackgroundFillColor()
Description copied from interface:SchemeDerivedColors
Returns the background fill color forthis
scheme.- Specified by:
getBackgroundFillColor
in interfaceSchemeDerivedColors
- Returns:
- The background fill color for
this
scheme.
-
getAccentedBackgroundFillColor
public java.awt.Color getAccentedBackgroundFillColor()
Description copied from interface:SchemeDerivedColors
Returns the accented background fill color forthis
scheme.- Specified by:
getAccentedBackgroundFillColor
in interfaceSchemeDerivedColors
- Returns:
- The accented background fill color for
this
scheme.
-
getTextBackgroundFillColor
public java.awt.Color getTextBackgroundFillColor()
Description copied from interface:SchemeDerivedColors
Returns the text background fill color forthis
scheme.- Specified by:
getTextBackgroundFillColor
in interfaceSchemeDerivedColors
- Returns:
- The text background fill color for
this
scheme.
-
getFocusRingColor
public java.awt.Color getFocusRingColor()
Description copied from interface:SchemeDerivedColors
Returns the focus ring color forthis
scheme.- Specified by:
getFocusRingColor
in interfaceSchemeDerivedColors
- Returns:
- The focus ring color for
this
scheme. - See Also:
RadianceSkin.getOverlayColor(RadianceThemingSlices.ColorOverlayType, RadianceThemingSlices.DecorationAreaType, ComponentState)
-
getSeparatorPrimaryColor
public java.awt.Color getSeparatorPrimaryColor()
Description copied from interface:SchemeDerivedColors
Returns the primary separator color forthis
scheme.- Specified by:
getSeparatorPrimaryColor
in interfaceSchemeDerivedColors
- Returns:
- The primary separator color for
this
scheme.
-
getSeparatorSecondaryColor
public java.awt.Color getSeparatorSecondaryColor()
Description copied from interface:SchemeDerivedColors
Returns the secondary separator color forthis
scheme.- Specified by:
getSeparatorSecondaryColor
in interfaceSchemeDerivedColors
- Returns:
- The secondary separator color for
this
scheme.
-
getMarkColor
public java.awt.Color getMarkColor()
Description copied from interface:SchemeDerivedColors
Returns the mark color forthis
scheme. Mark color is used on checkboxes, radio buttons, scrollbar arrows, combo arrows, menu arrows, etc.- Specified by:
getMarkColor
in interfaceSchemeDerivedColors
- Returns:
- The mark color for
this
scheme.
-
getEchoColor
public java.awt.Color getEchoColor()
Description copied from interface:SchemeDerivedColors
Returns the echo color forthis
scheme. Echo color is used for drawing slight echo / drop shadow around title pane texts and similar "primary" elements.- Specified by:
getEchoColor
in interfaceSchemeDerivedColors
- Returns:
- The echo color for
this
scheme.
-
shift
public RadianceColorScheme shift(java.awt.Color backgroundShiftColor, double backgroundShiftFactor, java.awt.Color foregroundShiftColor, double foregroundShiftFactor)
Description copied from interface:RadianceColorScheme
Creates a shift version ofthis
scheme.- Specified by:
shift
in interfaceRadianceColorScheme
- Parameters:
backgroundShiftColor
- Shift color for background colors. Should have full opacity.backgroundShiftFactor
- Value in 0.0...1.0 range. Larger values shift more towards the specified color.foregroundShiftColor
- Shift color for foreground colors. Should have full opacity.foregroundShiftFactor
- Value in 0.0...1.0 range. Larger values shift more towards the specified color.- Returns:
- Shift version of
this
scheme.
-
shiftBackground
public RadianceColorScheme shiftBackground(java.awt.Color backgroundShiftColor, double backgroundShiftFactor)
Description copied from interface:RadianceColorScheme
Creates a shift version ofthis
scheme.- Specified by:
shiftBackground
in interfaceRadianceColorScheme
- Parameters:
backgroundShiftColor
- Shift color for background colors. Should have full opacity.backgroundShiftFactor
- Value in 0.0...1.0 range. Larger values shift more towards the specified color.- Returns:
- Shift version of
this
scheme that does not change the foreground color.
-
tint
public RadianceColorScheme tint(double tintFactor)
Description copied from interface:RadianceColorScheme
Creates a tinted (shifted towards white) version ofthis
color scheme.- Specified by:
tint
in interfaceRadianceColorScheme
- Parameters:
tintFactor
- Value in 0.0...1.0 range. Larger values shift more towards white color.- Returns:
- Tinted version of
this
scheme.
-
tone
public RadianceColorScheme tone(double toneFactor)
Description copied from interface:RadianceColorScheme
Creates a toned (shifted towards gray) version ofthis
color scheme.- Specified by:
tone
in interfaceRadianceColorScheme
- Parameters:
toneFactor
- Value in 0.0...1.0 range. Larger values shift more towards gray color.- Returns:
- Toned version of
this
scheme.
-
shade
public RadianceColorScheme shade(double shadeFactor)
Description copied from interface:RadianceColorScheme
Creates a shaded (shifted towards black) version ofthis
color scheme.- Specified by:
shade
in interfaceRadianceColorScheme
- Parameters:
shadeFactor
- Value in 0.0...1.0 range. Larger values shift more towards black color.- Returns:
- Shaded version of
this
scheme.
-
saturate
public RadianceColorScheme saturate(double saturateFactor)
Description copied from interface:RadianceColorScheme
Creates a saturated or desaturated version ofthis
scheme. The value and brightness stay the same.- Specified by:
saturate
in interfaceRadianceColorScheme
- Parameters:
saturateFactor
- Value in -1.0...1.0 range. Positive values create more saturated colors. Negative values create more desaturated colors.- Returns:
- Saturated version of
this
scheme.
-
invert
public RadianceColorScheme invert()
Description copied from interface:RadianceColorScheme
Creates an inverted version ofthis
scheme.- Specified by:
invert
in interfaceRadianceColorScheme
- Returns:
- Inverted version of
this
scheme.
-
negate
public RadianceColorScheme negate()
Description copied from interface:RadianceColorScheme
Creates a negated version ofthis
scheme.- Specified by:
negate
in interfaceRadianceColorScheme
- Returns:
- Negated version of
this
scheme.
-
hueShift
public RadianceColorScheme hueShift(double hueShiftFactor)
Description copied from interface:RadianceColorScheme
Creates a hue-shifted (in HSB space) version ofthis
color scheme.- Specified by:
hueShift
in interfaceRadianceColorScheme
- Parameters:
hueShiftFactor
- Value in -1.0...1.0 range.- Returns:
- Hue-shifted version of
this
scheme.
-
blendWith
public RadianceColorScheme blendWith(RadianceColorScheme otherScheme, double likenessToThisScheme)
Description copied from interface:RadianceColorScheme
Creates a blended version ofthis
color scheme based on another color scheme.- Specified by:
blendWith
in interfaceRadianceColorScheme
- Parameters:
otherScheme
- The other color scheme for blending colors.likenessToThisScheme
- Defines how close the colors of the resulting color scheme are to this scheme. Value of 1.0 returns a color scheme with the exact colors of this color scheme. Value of 0.0 returns a color scheme with the exact colors of the other color scheme.- Returns:
- Blended color scheme.
-
named
public RadianceColorScheme named(java.lang.String colorSchemeDisplayName)
Description copied from interface:RadianceColorScheme
This method is a fluent-interface builder utility for setting the display name for this color scheme. The implementation must return the samethis
instance.- Specified by:
named
in interfaceRadianceColorScheme
- Parameters:
colorSchemeDisplayName
- New display name for this color scheme.- Returns:
- This color scheme.
-
-