1 person found this helpful
you need to assign a linkage id to your embedded font and you need to assign the font property of textFormat to be that linkage id.
addendum: you need to use setNewTextFormat() if you're assigning text after you assign a textformat.
Giving the linkage Id and setting the rtf.text before rtf.setTextFormat(textFormat) did the trick for getting the non-unicode characters work. The ZIPped testcase FLA online is updated now.
However, unicode chars still do not show up, only the non-unicode are displayed.
Strangely, the other textbox with embedded chars (Courier New in the testcase) is not messed up. However, if I'd go and change the font in the font symbol "Font01" from Arial to Courier New, that spoils the textbox whose font setting is literary "Courier New", not "Font01".
I am not sure why this happens. I've put the textbox on stage, and in its embedded characters settings the necessary embedded chars are specified. The fact that they are interpreted correctly (at least for textboxes with other than symbol fonts) is confirmed by the test of Courier New textbox -- all the special chars display correctly. Maybe those extra characters are just ignored, not embedded for the font symbols?
[Added] I've discovered that if I set the run-time textfield font to "Courier New" (that is, a font that is not specified as a font symbol), then also the run-time texfield displays the unicode chars. So, I can be almost happy, unless I want the run-time textfield be in the font that is specified in the library.
Case still not fully resolved...