public class Shadow extends java.lang.Object implements XMLReadable, java.lang.Cloneable, java.io.Serializable
限定符和类型 | 字段和说明 |
---|---|
static java.lang.String |
XML_TAG |
限定符和类型 | 方法和说明 |
---|---|
java.lang.Object |
clone() |
boolean |
equals(java.lang.Object object) |
java.awt.Color |
getShadowColor()
获取阴影的颜色
|
void |
paint(java.awt.Graphics g,
java.awt.Shape shape)
默认shape fill *
|
void |
paint(java.awt.Graphics g,
java.awt.Shape shape,
int strokeSize)
画阴影
|
void |
readXML(XMLableReader reader)
读取子节点,应该会被XMLableReader.readXMLObject()调用多次
|
void |
setShadowAlpha(float shadowAlpha)
设置阴影的透明度
|
void |
setShadowColor(java.awt.Color shadowColor)
设置阴影的颜色
|
void |
setShadowSize(int shadowSize)
设置阴影投影的长度
|
JSONObject |
toJSONObject()
转化为json对象数组
|
void |
writerXML(XMLPrintWriter writer)
写到xml文件里
|
public static final java.lang.String XML_TAG
public Shadow()
public Shadow(java.awt.Color shadowColor, int shadowSize, float shadowAlpha)
public void setShadowColor(java.awt.Color shadowColor)
shadowColor
- 颜色public java.awt.Color getShadowColor()
public void setShadowSize(int shadowSize)
shadowSize
- 长度public void setShadowAlpha(float shadowAlpha)
shadowAlpha
- 透明度,0到1之间的一个数值public void paint(java.awt.Graphics g, java.awt.Shape shape)
public void paint(java.awt.Graphics g, java.awt.Shape shape, int strokeSize)
strokeSize
- 折线的LineWidthpublic boolean equals(java.lang.Object object)
equals
在类中 java.lang.Object
public void readXML(XMLableReader reader)
XMLReadable
readXML
在接口中 XMLReadable
reader
- XML读取对象XMLableReader
public void writerXML(XMLPrintWriter writer)
writer
- xml写对象public java.lang.Object clone() throws java.lang.CloneNotSupportedException
clone
在类中 java.lang.Object
java.lang.CloneNotSupportedException
public JSONObject toJSONObject() throws JSONException
JSONException
- 出现异常