Rich Text Editor isn't showing embedded non-system fonts
I've searched high and low for a resolution to this problem. And as far as I
can tell there isn't a solution. So, please if anyone has a solution, I think
it would be worth a lot of peoples time, if we could actually post it here.
If you embed non-system fonts (below I've compiled true type fonts into
swf's), and reset the rich text editors fontArrayFamily to only contain the
newly embedded fonts, the embedded fonts will not work. If you embed system
fonts, this method will work. If you assign 1 of the non-embedded fonts to a
component, the font will render correctly. The issue only seems to be when the
fonts are assigned to the RTE, and the font families that are available to it.
Below should allow for non-system fonts to be available to the RTE, but you
will get default fonts instead.
<mx:Style>
@font-face {
src:url("AABIGFICTION.swf");
fontFamily: "AABIGFICTION";
}
@font-face {
src:url("Baskerville_Old_Face.swf");
fontFamily: "Baskerville_Old_Face";
}
</mx:Style>
<mx:Script>
<![CDATA[
private function returnHandler():void {
RTE.fontFamilyArray = ["AABIGFICTION", "Baskerville_Old_Face"];
}
]]>
</mx:Script>
<mx:RichTextEditor id="RTE" title="Title" width="440" height="368"
creationComplete="returnHandler();">
*NOTE*
*IF you assign the fontFamily within the RTE to 1 of the embedded non-system
fonts, it will render the font.
*Below AAGBIGFICTION will show, but you will not be able to use any other font.
****
<mx:RichTextEditor id="RTE" title="Title" width="440"
fontFamily="AABIGFICTION" height="368" creationComplete="returnHandler();">
|