|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.flagstone.transform.font.DefineFont
public final class DefineFont
DefineFont defines the glyphs that are drawn when text characters are rendered in a particular font.
A complete definition of a font is created using the DefineFont object for the glyphs along with an FontInfo or FontInfo2 object which contains the name of the font, whether the font face is bold or italics and a table that maps character codes to the glyphs that is drawn to represent the character.
FontInfo,
FontInfo2| Constructor Summary | |
|---|---|
DefineFont(DefineFont object)
Creates and initialises a DefineFont object using the values copied from another DefineFont object. |
|
DefineFont(int uid,
List<Shape> list)
Creates a DefineFont object setting the unique identifier for the object and the list of glyphs used to render the characters used from the font. |
|
DefineFont(SWFDecoder coder)
Creates and initialises a DefineFont object using values encoded in the Flash binary format. |
|
| Method Summary | |
|---|---|
DefineFont |
add(Shape obj)
Add a shape to the list of shapes that represent the glyphs for the font. |
DefineFont |
copy()
Creates a complete copy of this object. |
void |
encode(SWFEncoder coder,
Context context)
Encode an object to the Flash binary format. |
int |
getIdentifier()
Get the unique identifier assigned to this object. |
List<Shape> |
getShapes()
Get the list of shapes that define the outline for each glyph. |
int |
prepareToEncode(Context context)
Prepare an object for encoding, returning the expected size of an object when it is encoded. |
void |
setIdentifier(int uid)
Sets the unique identifier for an object within a given Movie. |
void |
setShapes(List<Shape> list)
Sets the list of shapes that describe each glyph. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public DefineFont(SWFDecoder coder)
throws IOException
coder - an SWFDecoder object that contains the encoded Flash data.
IOException - if an error occurs while decoding the data.
public DefineFont(int uid,
List<Shape> list)
uid - the unique identifier for this object.list - a list of Shape objects that define the outlines for each
glyph in the font.public DefineFont(DefineFont object)
object - a DefineFont object from which the values will be
copied.| Method Detail |
|---|
public int getIdentifier()
getIdentifier in interface DefineTagpublic void setIdentifier(int uid)
setIdentifier in interface DefineTaguid - a unique identifier for the object. Must be in the range
1..65535.public DefineFont add(Shape obj)
obj - a shape which must not be null.
public List<Shape> getShapes()
public void setShapes(List<Shape> list)
list - a list of Shape objects that define the outlines for each
glyph in the font. Must not be null.public DefineFont copy()
copy in interface Copyable<MovieTag>public String toString()
toString in class Objectpublic int prepareToEncode(Context context)
prepareToEncode in interface SWFEncodeablecontext - 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 SWFEncodeablecoder - 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 | |||||||||