Packageimpression.utilities
Classpublic class RTFConverter
InheritanceRTFConverter Inheritance Object

The RTFConverter class converts a subset of the Rich Text Format specification to Flash-conformant HTML.



Public Methods
 MethodDefined By
  
Creates a new instance of the RTFConverter class.
RTFConverter
  
clearStyle(style:String):void
Deletes a style property.
RTFConverter
  
convertRTF(source:String):String
Converts an RTF string into a Flash-conformant HTML string.
RTFConverter
  
getStyle(style:String):Object
Retrieves a style property.
RTFConverter
  
[static] Retrieves the default style map for the node.
RTFConverter
  
setStyle(style:String, value:Object):void
Sets a style property.
RTFConverter
Styles
 Style Description Defined By
  
bulletChar
Type: String
Specifies the character to use for the bullet for unordered lists. The default value is "●" (character code 0x25CF).
RTFConverter
  
bulletFont
Type: String
The font family name used for the bullet character in unordered lists. The default value is "Arial".
RTFConverter
  
bulletScale
Type: Number
Indicates the scale factor to use for the font size for the bullet character in unordered lists. The default value is 1.
RTFConverter
  
defaultTextFormat
Type: flash.text.TextFormat
The TextFormat object to use during conversion. The default value is null.
RTFConverter
  
embedFonts
Type: Boolean
Indicates whether embedded fonts should be used during conversion. The default value is false.
RTFConverter
  
forceDefaultFont
Type: Boolean
Indicates whether font changes in the source RTF should be removed and replaced with the default font name. The default value is false.
RTFConverter
  
tabStopInterval
Type: Number
Indicates the interval, in pixels, of tab stops used during conversion. Tab stops will be generated for every tabStopInterval interval from 0 to tabStopMax. The default value is 20.
RTFConverter
  
tabStopMax
Type: Boolean
Indicates the maximum value, of the tab stops used during conversion. The default value is 3000.
RTFConverter
Constructor Detail
RTFConverter()Constructor
public function RTFConverter()

Creates a new instance of the RTFConverter class.

Method Detail
clearStyle()method
public function clearStyle(style:String):void

Deletes a style property.

Parameters

style:String — The name of the style property.

See also

convertRTF()method 
public function convertRTF(source:String):String

Converts an RTF string into a Flash-conformant HTML string.

Parameters

source:String — An RTF string to convert.

Returns
String — A Flash-conformant HTML string containing the converted RTF from source.
getStyle()method 
public function getStyle(style:String):Object

Retrieves a style property.

Parameters

style:String — The name of the style property.

Returns
Object — Style value.

See also

getStyleDefinition()method 
public static function getStyleDefinition():Object

Retrieves the default style map for the node.

Returns
Object — Default styles object.

See also

setStyle()method 
public function setStyle(style:String, value:Object):void

Sets a style property.

Parameters

style:String — The name of the style property.
 
value:Object — The value of the style.

See also