Wednesday, June 2, 2010

ActionScript3 TextField

Over at http://as3.aule-browser.com/ I have been looking at ActionScript3 in SWF as a web-content language for text.

Text cannot be handled as it is in a Curl declarative-style file, but there are alternatives such as JSON (which Curl also handles well.)

The first challenge was in alignment of text: if a TextFormat is applied across only a range of a piece of text, the Flash TextField alignment, margins and indents break in peculiar fashion.

Anything that will use word-wrap should be multi-line with a TextFormat that is set with no range supplied.

The first thing you may miss are the Curl units which are not pixels.

If you build a Flex application instead of Flash (I am using FlashDevelop) there are other components available such as VBox, HBox and TExtArea much as in Curl.

It is hard to find anything to rival the Curl "live-code documentation" in the Curl IDE, but in the end the glitches ironed-out wrinkle-free.

No comments:

Post a Comment