Hiya, I am trying to create a movieclip that can be used as a button that has a textfield and also a box in the background behind the textfield that is relative to the width of the textfield. I want to do this so I can dynamically create a bunch of these MCs with different text as labels and that are all different widths according to how long the text is. The end result should be a bunch of MCs that have different text on them and that have boxes of varying widths relative to the text they contain.
When I create a textfield dynamically I have to specify the width first and so I can’t figure out how to choose the width after I have created the textfield, determined by it’s contents.
is there any way to do this without using fixed-width fonts and calculating the size of the textfield from this first before it is created? This is the only way i can think to do this.
Any sugggestions very gratefully received.