Flash 9 TextFields Rock!

Aug 11 2006 Published by under General

Check out some of the new methods on the Flash 9 TextField object. Some stuff we’ve been dying for for years. Here’s a nice one:


Returns a rectangle that is pretty much the bounding box of the character specified by the index parameter. In other words the first character in the text field would be index 0, etc.

Here’s a really quick, crappy demo of something you could do with that. Needs a lot of work, for example, it pukes if you search multiline text. Actually, it finds the positions fine, just doesn’t handle them correctly. Would be easy to fix, but I was just playing.

Just type in a word in the text (case sensitive) and hit search.

Neat, eh?

Source here.

14 responses so far. Comments will be closed after post is one year old.