Package org.zkoss.chart
Class Shadow
- java.lang.Object
-
- org.zkoss.chart.Optionable
-
- org.zkoss.chart.Shadow
-
- All Implemented Interfaces:
Serializable
,OptionDataListener
,org.zkoss.json.JSONAware
- Direct Known Subclasses:
PlotShadow
public class Shadow extends Optionable
A shadow option to set for the chart- Author:
- jumperchen
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static Shadow
NONE
No shadow at all-
Fields inherited from class org.zkoss.chart.Optionable
NOT_NULL_VALUE, options
-
-
Constructor Summary
Constructors Constructor Description Shadow()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Color
getColor()
Returns the color of the shadowNumber
getOffsetX()
Returns the offset X of the shadowNumber
getOffsetY()
Returns the offset Y of the shadowNumber
getOpacity()
Returns the opacity of the shadow.Number
getWidth()
Returns the width of the shadowvoid
setColor(String color)
Sets the color of the shadowvoid
setColor(Color color)
Sets the color of the shadowvoid
setColor(LinearGradient color)
Sets the color of the shadowvoid
setColor(RadialGradient color)
Sets the color of the shadowvoid
setOffsetX(int offsetX)
Sets the offset X of the shadowvoid
setOffsetY(Number offsetY)
Sets the offset Y of the shadowvoid
setOpacity(Number opacity)
Sets the opacity of the shadowvoid
setWidth(Number width)
Sets the width of the shadowString
toJSONString()
Encodes this object to a JSON string.-
Methods inherited from class org.zkoss.chart.Optionable
addExtraAttr, addOptionDataListener, clearOptonDataListener, clone, containsKey, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, getAttr, getAttr, getClientState, getExtraAttr, merge, onChange, removeExtraAttr, removeKey, removeOptionDataListener, setAttr, setAttr, setAttr, setAttr, toString
-
-
-
-
Field Detail
-
NONE
public static Shadow NONE
No shadow at all
-
-
Method Detail
-
getColor
public Color getColor()
Returns the color of the shadowDefault: black
-
setColor
public void setColor(Color color)
Sets the color of the shadow
-
setColor
public void setColor(String color)
Sets the color of the shadow
-
setColor
public void setColor(LinearGradient color)
Sets the color of the shadow
-
setColor
public void setColor(RadialGradient color)
Sets the color of the shadow
-
setOffsetX
public void setOffsetX(int offsetX)
Sets the offset X of the shadow
-
getOffsetX
public Number getOffsetX()
Returns the offset X of the shadowDefault: 1
-
setOffsetY
public void setOffsetY(Number offsetY)
Sets the offset Y of the shadow
-
getOffsetY
public Number getOffsetY()
Returns the offset Y of the shadowDefault: 1
-
setOpacity
public void setOpacity(Number opacity)
Sets the opacity of the shadow- Parameters:
opacity
-
-
getOpacity
public Number getOpacity()
Returns the opacity of the shadow.Default: 0.15 /
getWidth()
-
setWidth
public void setWidth(Number width)
Sets the width of the shadow
-
getWidth
public Number getWidth()
Returns the width of the shadowDefault: 3
-
toJSONString
public String toJSONString()
Description copied from class:Optionable
Encodes this object to a JSON string. It is the same asOptionable.toString()
.- Specified by:
toJSONString
in interfaceorg.zkoss.json.JSONAware
- Overrides:
toJSONString
in classOptionable
-
-