# TextFieldAutoSize.LEFT problem!

**URL:** https://forum.kirupa.com/t/textfieldautosize-left-problem/289091
**Category:** flash
**Created:** [May 26, 2009, 10:23am UTC](https://forum.kirupa.com/t/textfieldautosize-left-problem/289091 "2009-05-26T10:23:54Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![eskalation\_dk](https://avatars.discourse-cdn.com/v4/letter/e/aca169/32.png) [@eskalation\_dk](https://forum.kirupa.com/u/eskalation_dk)
#### Post date: [May 26, 2009, 10:23am UTC](https://forum.kirupa.com/t/textfieldautosize-left-problem/289091/1 "2009-05-26T10:23:54Z")

</div>

Hi all,

i have a problem with some rather large textFields in flash.

I load the string from XML, then parse it into dynamically created textFields, using an embedded font which is loaded beforehand.

these params are set:

```auto
var txtFld:TextField = new TextField();
   txtFld.embedFonts = true;
   txtFld.defaultTextFormat = new TextFormat("FacebusterRegular", 60, 0x353a3b);
   txtFld.mouseEnabled = false; 
   txtFld.wordWrap = true;
   txtFld.multiline = false;
   txtFld.selectable = false;
   txtFld.visible = false;
   buttonMode = true;
   useHandCursor = true;
   txtFld.addEventListener(MouseEvent.CLICK, onClick, false, 0, true);
   txtFld.text = "Some random text".toUpperCase();
   txtFld.autoSize = TextFieldAutoSize.LEFT;

```

unless i specify a width (Which i don’t want to), the text looks like this:  
SO  
ME  
RA  
ND  
OM  
TE  
XT,

instead of SOME RANDOM TEXT

What am i doing wrong?
