|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.vectomatic.dom.svg.OMCSSValue
org.vectomatic.dom.svg.OMSVGColor
public abstract class OMSVGColor
The OMSVGColor
interface corresponds
to color value definition for properties stop-color
, flood-color
and lighting-color
and is a base class for interface OMSVGPaint
. It incorporates SVG's extended notion
of color, which incorporates ICC-based color specifications.
Interface
OMSVGColor
does not correspond
to the <color> basic data
type. For the <color> basic
data type, the applicable DOM interfaces are defined in DOM
Level 2 Style; in particular, see the RGBColor
interface
([DOM2STYLE], section 2.2).
Note:
The OMSVGColor
interface is deprecated,
and may be dropped from future versions of the SVG specification.
Field Summary | |
---|---|
protected short |
colorType
|
protected OMSVGICCColor |
iccColor
|
protected OMRGBColor |
rgbColor
|
static short |
SVG_COLORTYPE_CURRENTCOLOR
Corresponds to when keyword currentColor has been specified. |
static short |
SVG_COLORTYPE_RGBCOLOR
An sRGB color has been specified without an alterICC color specification. |
static short |
SVG_COLORTYPE_RGBCOLOR_ICCCOLOR
An sRGB color has been specified along with an alterICC color specification. |
static short |
SVG_COLORTYPE_UNKNOWN
The color type is not one of predefined types. |
Fields inherited from class org.vectomatic.dom.svg.OMCSSValue |
---|
CSS_CUSTOM, CSS_INHERIT, CSS_PRIMITIVE_VALUE, CSS_VALUE_LIST, cssText, cssValueType |
Constructor Summary | |
---|---|
protected |
OMSVGColor()
|
Method Summary | |
---|---|
short |
getColorType()
The type of the value as specified by one of the SVG_COLORTYPE_ constants defined on this interface. |
OMSVGICCColor |
getIccColor()
The alternate ICC color specification. |
OMRGBColor |
getRgbColor()
The color specified in the sRGB color space. |
void |
setColor(short colorType,
String rgbColor,
String iccColor)
Sets the color value as specified by the parameters. |
void |
setRGBColor(String rgbColor)
Modifies the color value to be the specified sRGB color without an alternate ICC color specification. |
void |
setRGBColorICCColor(String rgbColor,
String iccColor)
Modifies the color value to be the specified sRGB color with an alternate ICC color specification. |
Methods inherited from class org.vectomatic.dom.svg.OMCSSValue |
---|
getCssText, getCssValueType, getDescription, setCssText, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final short SVG_COLORTYPE_UNKNOWN
public static final short SVG_COLORTYPE_RGBCOLOR
public static final short SVG_COLORTYPE_RGBCOLOR_ICCCOLOR
public static final short SVG_COLORTYPE_CURRENTCOLOR
protected short colorType
protected OMRGBColor rgbColor
protected OMSVGICCColor iccColor
Constructor Detail |
---|
protected OMSVGColor()
Method Detail |
---|
public final short getColorType()
public final OMRGBColor getRgbColor()
public final OMSVGICCColor getIccColor()
public final void setRGBColor(String rgbColor) throws com.google.gwt.core.client.JavaScriptException
rgbColor
- A string that matches <color>,
which specifies the new sRGB color value.
SVGException(SVG_INVALID_VALUE_ERR)
- Raised if rgbColor
does not match <color>.
com.google.gwt.core.client.JavaScriptException
public final void setRGBColorICCColor(String rgbColor, String iccColor) throws com.google.gwt.core.client.JavaScriptException
rgbColor
- A string that matches <color>,
which specifies the new sRGB color value.iccColor
- A string that matches <icccolor>,
which specifies the alternate ICC color specification.
SVGException(SVG_INVALID_VALUE_ERR)
- Raised if rgbColor
does not match <color> or
if iccColor does not match <icccolor>.
com.google.gwt.core.client.JavaScriptException
public final void setColor(short colorType, String rgbColor, String iccColor) throws com.google.gwt.core.client.JavaScriptException
RGBColor
, then rgbColor must be a string
that matches <color>; otherwise,
rgbColor. must be null. If colorType requires an
OMSVGICCColor
, then iccColor
must be a string that matches <icccolor>;
otherwise, iccColor must be null.
colorType
- One of the defined constants for getColorType()
.rgbColor
- The specification of an sRGB color, or null.iccColor
- The specification of an ICC color, or null.
SVGException(SVG_INVALID_VALUE_ERR)
- Raised if one of the parameters
has an invalid value.
com.google.gwt.core.client.JavaScriptException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |