Answered
CharacterFormat
Hi,
I have some problems using CharacterFormat. The code below set char color and size, bat not fontFamily or fontWeight.....
Thanks!
I have some problems using CharacterFormat. The code below set char color and size, bat not fontFamily or fontWeight.....
quote:
var styleList:String = "Arial,13,0x000000,bold,";
var charFormat:CharacterFormat = new CharacterFormat();
var arrStyles:Array = styleList.split(",");
charFormat.fontFamily = arrStyles[0];
charFormat.fontSize = arrStyles[1];
charFormat.color = arrStyles[2];
charFormat.fontWeight = arrStyles[3];
charFormat.fontStyle = arrStyles[4];
charFormat.fontLookup = flash.text.engine.FontLookup.EMBEDDED_CFF;
charFormat.kerning = flash.text.engine.Kerning.ON;
textFlow.characterFormat = charFormat;
//required to show the style changes
textFlow.flowComposer.updateAllContainers();
Thanks!
