Weird issues with embedded fonts and TLF
Hello all,
I am working on a fairly complex designer tool that allows the user to add text items to a stage and manipultate the text wysiwyg style.
I have it all working well, and the textflow info is saved to the database through a webservice. However I am experiancing an odd issue.
This is the code I am using to load up the textflow:
GlobalSettings.resolveFontLookupFunction = null;
var tf:TextFlow = TextFlowUtil.importFromXML(res.children()[0],"preserve");
tf.renderingMode = RenderingMode.CFF;
tf.fontLookup = FontLookup.EMBEDDED_CFF;
txt.textFlow = tf;
txt.textFlow.invalidateAllFormats();
txt is my richeditabletext object.
When my stored textflow calls for an embedded font, it wont render properly the first time, it just falls back to the ugly default font, then If I trigger the above code a second time, replacing the textflow again, the correct font appears. Does anyone see anything in my code that is wrong?
Thanks
Jason
