flash - TextField's size in Flex -


i'm converting code project flash 3 flex 4. i've got problem textfield controls. text placed in doesn't appear. i've checked thoroughly , width equal 4. no matter text placed in it, narrow. know in flex, should provide width , height explicitly components there issues:

  1. i don't know initial size of such field - want automatically determine size based on text stores
  2. there couple of other containers contain , should resize automatically too, have correct size display content of textfield.

thanks

first, i'll assume you're using uitextfield. if not, use one.

having out of way, set autosize property textfieldautosize.right, , leave width undefined. if have text multiple lines, or text won't fit in line want displayed, you'll want set width of field percentage, 100% (percentagewidth actionscript, width mxml), , leave height undefined.

if there containers need resized, i'd recommend using vbox/hbox instead of whatever you're using , leaving widths (and possibly heights) undefined on them.

labels components use textfields setup in such way resize on 1 line only. if don't want use them can check source code.

text component similar label allows multiple lines. again, advise checking out source code.


Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -