I am trying to code a text ticker that can animate in many directions. I am have trouble doing the following:
-
Having text that generates correctly, using “font symbols” in the library defined in the textFormat object.
-
Having said text display when a mask was applied to it. (Text is not displaying)
My textFormat object is the following:
_txtFormat = new TextFormat ();
_txtFormat.font = "kroeger05_56_bold";
_txtFormat.color = 0x000000;
_txtFormat.size = 8;
And my generator is this method:
private function txtFieldGenerator (depth:Number, line:String):MovieClip
{
var mc = _content.createEmptyMovieClip ("txtMC_" + depth, depth);
var field_txt = mc.createTextField ("txt", 0, 0, 0, 0, 0);
field_txt.text = line;
field_txt.embedFonts = true;
field_txt.setTextFormat (_txtFormat);
field_txt.autoSize = "left";
trace(mc._y)
return mc;
}
What I’m getting is a text field that does not have the right font (the
default font). And when I turn on masking in the class it wont show up
at all. Does anyone have any insight? Thanks in advance.