You set the width of the button using myButton.setSize(width, height); and im not sure but I think if you have a reference to the label text field you can use label._width = label.textWidth;
Hope this helped. Jim -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Polk Sent: 02 March 2006 19:02 To: [email protected] Subject: [Flashcoders] v2 Button Label width? I have searched google, the list, MM/Adobe, help files and my new book, "Advanced Components". I cannot seem to figure out how to determine the width of the Label embedded into the v2 Button component. I will be loading many different languages via Unicode into the label and will not know the exact size to set until I have fed the text into it. In looping through its properties I have determined the Label is stored in labelPath. The other option I am trying to avoid is rendering an identical string into an invisible label component to determine its size. The only option I see right now, is using a non-monospaced font. Any help would be appreciated. Thanks, Steve _______________________________________________ [email protected] To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com _______________________________________________ [email protected] To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com

