all groups > flash actionscript > october 2004 >
You're in the

flash actionscript

group:

Text align = center doesn't work


Text align = center doesn't work Sir Zaire
10/17/2004 7:48:35 PM
flash actionscript:
Hello

I have dynamicaly created a text field, and i need it to be: align = center ,
but it doesn't work.

That's the code i'm using :

ftt = new TextFormat();
ftt.font = "Rotis";
ftt.size = 25;
ftt.color = 0xBA122B;
ftt.leading = 3;
ftt.leftMargin = "0";
ftt.rightMargin = "0";

_root.createTextField("titulo", 30, 320, 20, 160, 30);
_root.titulo.text = "A Nossa Miss?o";
_root.titulo.align = "center";
_root.titulo.embedFonts = true;
_root.titulo.selectable = false;
_root.titulo.setTextFormat(ftt);

I hope someone can help me.
Re: Text align = center doesn't work _jrh_
10/17/2004 7:51:05 PM
Try:

_root.titulo.autoSize = "center";

Re: Text align = center doesn't work Sir Zaire
10/17/2004 9:47:07 PM
Hello again

Re: Text align = center doesn't work _jrh_
10/18/2004 1:02:23 AM
AddThis Social Bookmark Button