pt.tumba.parser.swf
Class EditField

java.lang.Object
  extended by pt.tumba.parser.swf.Symbol
      extended by pt.tumba.parser.swf.EditField

public class EditField
extends Symbol

An Edit Field Symbol. In order to limit the chars in the field use a separate font and only load those glyphs that are required.

Author:
unknown

Field Summary
protected  int alignment
          Description of the Field
protected  int charLimit
          Description of the Field
protected  java.lang.String fieldName
          Description of the Field
protected  Font font
          Description of the Field
protected  double fontSize
          Description of the Field
protected  boolean hasBorder
          Description of the Field
protected  boolean hasWordWrap
          Description of the Field
protected  double indentation
          Description of the Field
protected  java.lang.String initialText
          Description of the Field
protected  boolean isEditable
          Description of the Field
protected  boolean isHtml
          Description of the Field
protected  boolean isMultiline
          Description of the Field
protected  boolean isPassword
          Description of the Field
protected  boolean isSelectable
          Description of the Field
protected  double leftMargin
          Description of the Field
protected  double lineSpacing
          Description of the Field
protected  double maxX
          Description of the Field
protected  double maxY
          Description of the Field
protected  double minX
          Description of the Field
protected  double minY
          Description of the Field
protected  double rightMargin
          Description of the Field
protected  AlphaColor textColor
          Description of the Field
protected  boolean usesSystemFont
          Description of the Field
 
Fields inherited from class pt.tumba.parser.swf.Symbol
id
 
Constructor Summary
EditField(java.lang.String fieldName, java.lang.String initialText, Font font, double fontSize, double minX, double minY, double maxX, double maxY)
          Create an Edit Field with black text and default settings
 
Method Summary
protected  int defineSymbol(Movie movie, SWFTagTypes timelineWriter, SWFTagTypes definitionWriter)
          Description of the Method
 int getAlignment()
          Gets the alignment attribute of the EditField object
 int getCharLimit()
          Gets the charLimit attribute of the EditField object
 java.lang.String getFieldName()
          Gets the fieldName attribute of the EditField object
 Font getFont()
          Gets the font attribute of the EditField object
 double getFontSize()
          Gets the fontSize attribute of the EditField object
 double getIndentation()
          Gets the indentation attribute of the EditField object
 java.lang.String getInitialText()
          Gets the initialText attribute of the EditField object
 double getLeftMargin()
          Gets the leftMargin attribute of the EditField object
 double getLineSpacing()
          Gets the lineSpacing attribute of the EditField object
 double getMaxX()
          Gets the maxX attribute of the EditField object
 double getMaxY()
          Gets the maxY attribute of the EditField object
 double getMinX()
          Gets the minX attribute of the EditField object
 double getMinY()
          Gets the minY attribute of the EditField object
 double getRightMargin()
          Gets the rightMargin attribute of the EditField object
 AlphaColor getTextColor()
          Gets the textColor attribute of the EditField object
 boolean hasBorder()
          Description of the Method
 boolean hasWordWrap()
          Description of the Method
 boolean isEditable()
          Gets the editable attribute of the EditField object
 boolean isHtml()
          Gets the html attribute of the EditField object
 boolean isMultiline()
          Gets the multiline attribute of the EditField object
 boolean isPassword()
          Gets the password attribute of the EditField object
 boolean isSelectable()
          Gets the selectable attribute of the EditField object
 void setAlignment(int alignment)
          Sets the alignment attribute of the EditField object
 void setCharLimit(int charLimit)
          Sets the charLimit attribute of the EditField object
 void setFieldName(java.lang.String name)
          Sets the fieldName attribute of the EditField object
 void setFont(Font font)
          Sets the font attribute of the EditField object
 void setFontSize(double fontSize)
          Sets the fontSize attribute of the EditField object
 void setIndentation(double indentation)
          Sets the indentation attribute of the EditField object
 void setInitialText(java.lang.String text)
          Sets the initialText attribute of the EditField object
 void setLeftMargin(double leftMargin)
          Sets the leftMargin attribute of the EditField object
 void setLineSpacing(double lineSpacing)
          Sets the lineSpacing attribute of the EditField object
 void setMaxX(double maxX)
          Sets the maxX attribute of the EditField object
 void setMaxY(double maxY)
          Sets the maxY attribute of the EditField object
 void setMinX(double minX)
          Sets the minX attribute of the EditField object
 void setMinY(double minY)
          Sets the minY attribute of the EditField object
 void setProperties(boolean isSelectable, boolean hasBorder, boolean isHtml, boolean usesSystemFont, boolean hasWordWrap, boolean isMultiline, boolean isPassword, boolean isEditable)
          Sets the properties attribute of the EditField object
 void setRightMargin(double rightMargin)
          Sets the rightMargin attribute of the EditField object
 void setTextColor(AlphaColor color)
          Sets the textColor attribute of the EditField object
 boolean usesSystemFont()
          Description of the Method
 
Methods inherited from class pt.tumba.parser.swf.Symbol
define, getId, getNextId
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

textColor

protected AlphaColor textColor
Description of the Field


alignment

protected int alignment
Description of the Field


charLimit

protected int charLimit
Description of the Field


leftMargin

protected double leftMargin
Description of the Field


rightMargin

protected double rightMargin
Description of the Field


indentation

protected double indentation
Description of the Field


lineSpacing

protected double lineSpacing
Description of the Field


fieldName

protected java.lang.String fieldName
Description of the Field


initialText

protected java.lang.String initialText
Description of the Field


font

protected Font font
Description of the Field


fontSize

protected double fontSize
Description of the Field


minX

protected double minX
Description of the Field


minY

protected double minY
Description of the Field


maxX

protected double maxX
Description of the Field


maxY

protected double maxY
Description of the Field


isSelectable

protected boolean isSelectable
Description of the Field


hasBorder

protected boolean hasBorder
Description of the Field


isHtml

protected boolean isHtml
Description of the Field


usesSystemFont

protected boolean usesSystemFont
Description of the Field


hasWordWrap

protected boolean hasWordWrap
Description of the Field


isMultiline

protected boolean isMultiline
Description of the Field


isPassword

protected boolean isPassword
Description of the Field


isEditable

protected boolean isEditable
Description of the Field

Constructor Detail

EditField

public EditField(java.lang.String fieldName,
                 java.lang.String initialText,
                 Font font,
                 double fontSize,
                 double minX,
                 double minY,
                 double maxX,
                 double maxY)
Create an Edit Field with black text and default settings

Parameters:
fieldName - may be null
initialText - Description of the Parameter
font - Description of the Parameter
fontSize - Description of the Parameter
minX - Description of the Parameter
minY - Description of the Parameter
maxX - Description of the Parameter
maxY - Description of the Parameter
Method Detail

isSelectable

public boolean isSelectable()
Gets the selectable attribute of the EditField object

Returns:
The selectable value

hasBorder

public boolean hasBorder()
Description of the Method

Returns:
Description of the Return Value

isHtml

public boolean isHtml()
Gets the html attribute of the EditField object

Returns:
The html value

usesSystemFont

public boolean usesSystemFont()
Description of the Method

Returns:
Description of the Return Value

hasWordWrap

public boolean hasWordWrap()
Description of the Method

Returns:
Description of the Return Value

isMultiline

public boolean isMultiline()
Gets the multiline attribute of the EditField object

Returns:
The multiline value

isPassword

public boolean isPassword()
Gets the password attribute of the EditField object

Returns:
The password value

isEditable

public boolean isEditable()
Gets the editable attribute of the EditField object

Returns:
The editable value

setProperties

public void setProperties(boolean isSelectable,
                          boolean hasBorder,
                          boolean isHtml,
                          boolean usesSystemFont,
                          boolean hasWordWrap,
                          boolean isMultiline,
                          boolean isPassword,
                          boolean isEditable)
Sets the properties attribute of the EditField object

Parameters:
isSelectable - The new properties value
hasBorder - The new properties value
isHtml - The new properties value
usesSystemFont - The new properties value
hasWordWrap - The new properties value
isMultiline - The new properties value
isPassword - The new properties value
isEditable - The new properties value

getTextColor

public AlphaColor getTextColor()
Gets the textColor attribute of the EditField object

Returns:
The textColor value

getAlignment

public int getAlignment()
Gets the alignment attribute of the EditField object

Returns:
The alignment value

getCharLimit

public int getCharLimit()
Gets the charLimit attribute of the EditField object

Returns:
The charLimit value

getLeftMargin

public double getLeftMargin()
Gets the leftMargin attribute of the EditField object

Returns:
The leftMargin value

getRightMargin

public double getRightMargin()
Gets the rightMargin attribute of the EditField object

Returns:
The rightMargin value

getIndentation

public double getIndentation()
Gets the indentation attribute of the EditField object

Returns:
The indentation value

getLineSpacing

public double getLineSpacing()
Gets the lineSpacing attribute of the EditField object

Returns:
The lineSpacing value

getFieldName

public java.lang.String getFieldName()
Gets the fieldName attribute of the EditField object

Returns:
The fieldName value

getInitialText

public java.lang.String getInitialText()
Gets the initialText attribute of the EditField object

Returns:
The initialText value

getFont

public Font getFont()
Gets the font attribute of the EditField object

Returns:
The font value

getFontSize

public double getFontSize()
Gets the fontSize attribute of the EditField object

Returns:
The fontSize value

getMinX

public double getMinX()
Gets the minX attribute of the EditField object

Returns:
The minX value

getMinY

public double getMinY()
Gets the minY attribute of the EditField object

Returns:
The minY value

getMaxX

public double getMaxX()
Gets the maxX attribute of the EditField object

Returns:
The maxX value

getMaxY

public double getMaxY()
Gets the maxY attribute of the EditField object

Returns:
The maxY value

setTextColor

public void setTextColor(AlphaColor color)
Sets the textColor attribute of the EditField object

Parameters:
color - The new textColor value

setAlignment

public void setAlignment(int alignment)
Sets the alignment attribute of the EditField object

Parameters:
alignment - The new alignment value

setCharLimit

public void setCharLimit(int charLimit)
Sets the charLimit attribute of the EditField object

Parameters:
charLimit - The new charLimit value

setLeftMargin

public void setLeftMargin(double leftMargin)
Sets the leftMargin attribute of the EditField object

Parameters:
leftMargin - The new leftMargin value

setRightMargin

public void setRightMargin(double rightMargin)
Sets the rightMargin attribute of the EditField object

Parameters:
rightMargin - The new rightMargin value

setIndentation

public void setIndentation(double indentation)
Sets the indentation attribute of the EditField object

Parameters:
indentation - The new indentation value

setLineSpacing

public void setLineSpacing(double lineSpacing)
Sets the lineSpacing attribute of the EditField object

Parameters:
lineSpacing - The new lineSpacing value

setFieldName

public void setFieldName(java.lang.String name)
Sets the fieldName attribute of the EditField object

Parameters:
name - The new fieldName value

setInitialText

public void setInitialText(java.lang.String text)
Sets the initialText attribute of the EditField object

Parameters:
text - The new initialText value

setFont

public void setFont(Font font)
Sets the font attribute of the EditField object

Parameters:
font - The new font value

setFontSize

public void setFontSize(double fontSize)
Sets the fontSize attribute of the EditField object

Parameters:
fontSize - The new fontSize value

setMinX

public void setMinX(double minX)
Sets the minX attribute of the EditField object

Parameters:
minX - The new minX value

setMinY

public void setMinY(double minY)
Sets the minY attribute of the EditField object

Parameters:
minY - The new minY value

setMaxX

public void setMaxX(double maxX)
Sets the maxX attribute of the EditField object

Parameters:
maxX - The new maxX value

setMaxY

public void setMaxY(double maxY)
Sets the maxY attribute of the EditField object

Parameters:
maxY - The new maxY value

defineSymbol

protected int defineSymbol(Movie movie,
                           SWFTagTypes timelineWriter,
                           SWFTagTypes definitionWriter)
                    throws java.io.IOException
Description of the Method

Specified by:
defineSymbol in class Symbol
Parameters:
movie - Description of the Parameter
timelineWriter - Description of the Parameter
definitionWriter - Description of the Parameter
Returns:
Description of the Return Value
Throws:
java.io.IOException - Description of the Exception