|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.flagstone.transform.shape.ShapeStyle2
public final class ShapeStyle2
ShapeStyle2 extends the functionality of ShapeStyle by supporting lines drawn with the LineStyle2 object.
Constructor Summary | |
---|---|
ShapeStyle2()
Creates an uninitialised ShapeStyle object. |
|
ShapeStyle2(int flags,
SWFDecoder coder,
Context context)
Creates and initialises a ShapeStyle object using values encoded in the Flash binary format. |
|
ShapeStyle2(ShapeStyle2 object)
Creates and initialises a ShapeStyle object using the values copied from another ShapeStyle object. |
Method Summary | |
---|---|
ShapeStyle2 |
add(FillStyle style)
Add the fill style object to the list of fill styles. |
ShapeStyle2 |
add(LineStyle2 style)
Add a LineStyle object to the list of line styles. |
ShapeStyle2 |
copy()
Creates a complete copy of this object. |
void |
encode(SWFEncoder coder,
Context context)
Encode an object to the Flash binary format. |
Integer |
getAltFillStyle()
Get the index of the fill style that will be applied to any overlapping area filled. |
Integer |
getFillStyle()
Get the index of the fill style that will be applied to any area filled. |
List<FillStyle> |
getFillStyles()
Returns the list of new fill styles. |
Integer |
getLineStyle()
Get the index of the line style that will be applied to any line drawn. |
List<LineStyle2> |
getLineStyles()
Get the list of new line styles. |
Integer |
getMoveX()
Get the x-coordinate of any relative move or null if no move is specified. |
Integer |
getMoveY()
Get the y-coordinate of any relative move or null if no move is specified. |
int |
prepareToEncode(Context context)
Prepare an object for encoding, returning the expected size of an object when it is encoded. |
ShapeStyle2 |
setAltFillStyle(Integer anIndex)
Sets the index of the fill style that will be applied to any overlapping area filled. |
ShapeStyle2 |
setFillStyle(Integer anIndex)
Sets the index of the fill style that will be applied to any area filled. |
ShapeStyle2 |
setFillStyles(List<FillStyle> list)
Sets the list of new fill styles. |
ShapeStyle2 |
setLineStyle(Integer anIndex)
Sets the index of the line style that will be applied to any line drawn. |
ShapeStyle2 |
setLineStyles(List<LineStyle2> list)
Sets the list of new line styles. |
ShapeStyle2 |
setMove(Integer xCoord,
Integer yCoord)
Sets the coordinates of any relative move. |
ShapeStyle2 |
setMoveX(Integer coord)
Sets the x-coordinate of any relative move. |
ShapeStyle2 |
setMoveY(Integer coord)
Sets the x-coordinate of any relative move. |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public ShapeStyle2(int flags, SWFDecoder coder, Context context) throws IOException
flags
- contains fields identifying which fields are optionally
encoded in the data - decoded by parent object.coder
- an SWFDecoder object that contains the encoded Flash data.context
- a Context object used to manage the decoders for different
type of object and to pass information on how objects are
decoded.
IOException
- if an error occurs while decoding the data.public ShapeStyle2()
public ShapeStyle2(ShapeStyle2 object)
object
- a ShapeStyle object from which the values will be
copied.Method Detail |
---|
public ShapeStyle2 add(LineStyle2 style)
style
- and LineStyle object. Must not be null.
public ShapeStyle2 add(FillStyle style)
style
- and FillStyle object. Must not be null.
public Integer getMoveX()
public Integer getMoveY()
public Integer getLineStyle()
public Integer getFillStyle()
public Integer getAltFillStyle()
public List<LineStyle2> getLineStyles()
public List<FillStyle> getFillStyles()
public ShapeStyle2 setMoveX(Integer coord)
coord
- move the current point by aNumber in the x direction. Must be
in the range -65535..65535.
public ShapeStyle2 setMoveY(Integer coord)
coord
- move the current point by aNumber in the x direction. Must be
in the range -65535..65535.
public ShapeStyle2 setMove(Integer xCoord, Integer yCoord)
xCoord
- move the current point by aNumber in the x direction. Must be
in the range -65535..65535.yCoord
- move the current point by aNumber in the y direction. Must be
in the range -65535..65535.
public ShapeStyle2 setFillStyle(Integer anIndex)
anIndex
- selects the fill style at anIndex in the fill styles list of
the parent Shape object.
public ShapeStyle2 setAltFillStyle(Integer anIndex)
anIndex
- selects the alternate fill style at anIndex in the fill styles
list of the parent Shape object.
public ShapeStyle2 setLineStyle(Integer anIndex)
anIndex
- selects the line style at anIndex in the line styles list of
the parent Shape object.
public ShapeStyle2 setLineStyles(List<LineStyle2> list)
list
- a list of LineStyle objects. Must not be null.
public ShapeStyle2 setFillStyles(List<FillStyle> list)
list
- a list of fill style objects. Must not be null.
public ShapeStyle2 copy()
copy
in interface Copyable<ShapeRecord>
public String toString()
toString
in class Object
public int prepareToEncode(Context context)
prepareToEncode
in interface SWFEncodeable
context
- an Context that allows information to be passed between
objects to control how they are initialised for encoding.
public void encode(SWFEncoder coder, Context context) throws IOException
encode
in interface SWFEncodeable
coder
- an SWFEncoder object.context
- an Context that allows information to be passed between
objects to control how they are initialised for encoding.
IOException
- if an error occurs while encoding the object.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |