public class ColorWithFallback
extends org.apache.xmlgraphics.java2d.color.ColorWithAlternatives
Color subclass adding a fallback color that FOP uses to re-serialize
color specifications as textual functions. The fallback is otherwise not used in producing
output formats.| Constructor and Description |
|---|
ColorWithFallback(java.awt.Color color,
java.awt.Color fallback)
Copy constructor adding a fallback color.
|
ColorWithFallback(java.awt.color.ColorSpace cspace,
float[] components,
float alpha,
java.awt.Color[] alternativeColors,
java.awt.Color fallback)
Creates a new color
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object obj) |
java.awt.Color |
getFallbackColor()
Returns the fallback color.
|
int |
hashCode() |
getAlternativeColors, getFirstAlternativeOfType, hasAlternativeColors, hasSameAlternativeColorsbrighter, createContext, darker, decode, getAlpha, getBlue, getColor, getColor, getColor, getColorComponents, getColorComponents, getColorSpace, getComponents, getComponents, getGreen, getHSBColor, getRed, getRGB, getRGBColorComponents, getRGBComponents, getTransparency, HSBtoRGB, RGBtoHSB, toStringpublic ColorWithFallback(java.awt.color.ColorSpace cspace,
float[] components,
float alpha,
java.awt.Color[] alternativeColors,
java.awt.Color fallback)
cspace - the color space of the primary colorcomponents - the color componentsalpha - the alpha componentalternativeColors - the array of alternative colors if applicable (may be null)fallback - the fallback color (usually an sRGB color)public ColorWithFallback(java.awt.Color color,
java.awt.Color fallback)
color - the color to be duplicatedfallback - the fallback color (usually an sRGB color)public java.awt.Color getFallbackColor()
public int hashCode()
hashCode in class org.apache.xmlgraphics.java2d.color.ColorWithAlternativespublic boolean equals(java.lang.Object obj)
equals in class java.awt.ColorCopyright 1999-2022 The Apache Software Foundation. All Rights Reserved.