Forum Moderators: open

Message Too Old, No Replies

How to re-size text field (w/actionscript) without re-sizing text

         

benlieb

5:04 am on Feb 20, 2006 (gmt 0)

10+ Year Member



Anyone know how to dynamically re-size a text field without having the text warp?

dareRock

2:41 pm on Feb 28, 2006 (gmt 0)

10+ Year Member



not sure why there are no replies on this - maybe b/c it's an easy question...

on (release){
txtField._width = 500;
}

would be a button that changes the width of a dynamic text field to 500 px - now if txtField was inside a mc called 'myMovieClip', then it would have to be...

myMovieClip.txtField._width = 500 otherwise since myMovieClip._width - 500 would stretcht he movie clip to 500 px and everything inside the clip would stretch visually.

hope that helps

dareRock

2:42 pm on Feb 28, 2006 (gmt 0)

10+ Year Member



the '- 500' in my last note should be '= 500'

dareRock

2:44 pm on Feb 28, 2006 (gmt 0)

10+ Year Member



actually, just verified my own response and when you resize a 'dynamic text field' text sizing will stay the same, if you use a 'static text field' then the stretching occurs