Search code examples
htmlapache-flexflashadobetlf

Adobe TLF and HTML


What is the best way to convert a tlf markup to HTML? I want only standar HTML without the old font tag. I think I saw a utility created by someone for this, but I can remember where it is. any ideas?

Tks.


Solution

  • http://help.adobe.com/en_US/ActionScript/3.0_ProgrammingAS3_Flex/WSc3ff6d0ea7785946579a18b01205e1c5646-7fef.html

    var ptext:String = "Hello, World"; 
    var flow:TextFlow = TextConverter.importToFlow(ptext, TextConverter.PLAIN_TEXT_FORMAT); 
    var out:XML = TextConverter.export(flow, TextConverter.TEXT_LAYOUT_FORMAT, ConversionType.XML_TYPE );
    

    but use TextConverter.TEXT_FIELD_HTML_FORMAT instead of TextConverter.PLAIN_TEXT_FORMAT