TextLayoutFormat & TLFTextField
Hi All,
I try to change TextLayoutFormat of TLFTextField. I can change format only after create and adding TLFTextField to stage. Then I try to call getChild() and change it but nothing has happens. Here is a part of my code. "text_child" is TLFTextField on Stage.
//---------------------------
import fl.text.TLFTextField;
import flashx.textLayout.formats.TextLayoutFormat;
import flashx.textLayout.elements.TextFlow;
var text_create : TLFTextField = new TLFTextField();
addChild(text_create);
text_child.text = "text child";
text_create.text = "text create";
var myFormat:TextLayoutFormat = new TextLayoutFormat();
myFormat.color = 0x336633;
myFormat.fontSize = 24;
var myTextFlow : TextFlow;
myTextFlow = text_create.textFlow;
myTextFlow.hostFormat = myFormat;
myTextFlow.flowComposer.updateAllControllers();
myTextFlow = text_child.textFlow;
myTextFlow.hostFormat = myFormat;
myTextFlow.flowComposer.updateAllControllers();
