Hello FlashCoders.
The seemingly simple task of splitting a Textfield into it's (soft)
wrapped lines is alluding me.
How can you tell the Text content of a particular line within a
Textfield? I'm trying to split out the individual lines to animate
them.
Thanks,
Dan
Dan Efergan
dan
Hi,
it might be simplest (if the text is one size only) to dump the whole
textfield into a bitmap and take it from there.
greetz
JC
On 8/16/07, Dan Efergan [EMAIL PROTECTED] wrote:
Hello FlashCoders.
The seemingly simple task of splitting a Textfield into it's (soft)
wrapped lines is
Dan,
It's a bit repetitive, but you can work it out with
TextFormat.getTextExtent(). Just keep adding characters until the rect's
height changes. (It's also - at least in Flash 8 - slightly incorrect when
using antialiased fonts).
Ian
On 8/16/07, Dan Efergan [EMAIL PROTECTED] wrote:
Hello
Thanks so far.
I suppose I could do something similar to the TextExtent thing
filling up a textfield and checking it's textheight (does textheight
update without a redraw?).
At least then it wouldn't be a deprecated command.
And I'm thinking cutting down processing by using making an
Check out Jack's great Text Metrics class. He just posted this Aug. 7th.
http://www.greensock.com/ActionScript/TextMetrics/
cheers,
Jon
On Aug 16, 2007, at 8:47 AM, Dan Efergan wrote:
Hello FlashCoders.
The seemingly simple task of splitting a Textfield into it's (soft)
wrapped lines is
Thanks very much! Haven't looked through yet, but that looks like
it's going to save me an afternoon :-)
Dan
On 16 Aug 2007, at 14:41, Jon Bradley wrote:
Check out Jack's great Text Metrics class. He just posted this Aug.
7th.
http://www.greensock.com/ActionScript/TextMetrics/
cheers,
Hi Dan,
getTextExtent() isn't actually deprecated - it's an (acknowledged) bug in
the documentation.
Ian
On 8/16/07, Dan Efergan [EMAIL PROTECTED] wrote:
Thanks so far.
I suppose I could do something similar to the TextExtent thing
filling up a textfield and checking it's textheight (does
7 matches
Mail list logo