Embedding fonts in Flash CS3
Posted on 20th September 2007 in Developer tools, Flash | 14 Comments »
Font management in Flash has never been worth a wow but in CS3 Adobe has forgotten proper font embedding at all.
In previous versions (e.g. CS2) it was possible to create a Font instance in the library. The same procedure is there in CS3:
But even though it’s there only Basic Latin characters make it through the compilation process and there’s no unicode range for the font instance in the resulting SWF file. Yet the trouble goes deeper than that. If you’ve previously used Font Symbol Name for your TextFormat definitions in ActionScript that is no more the case.
If the Font instance was exported for ActionScript as Bitmap text, Flash will change the instance name to the font’s actual name postfixed with _8pt_st if the font size in the Font Symbol Properties dialog was 8pt. If the font was not exported as Bitmap text, font name remains and the instance name given in Font Symbol Properties dialog is actually ignored.
There’s no real workaround for proper font embedding in Flash CS3 IDE so far. The only recommendation would be to use common character embedding to an on-Stage TextField and use it as a shared resource application-wide:
It has been reported that some of the characters embedded may appear erroneously and look garbled. It is unknown why it happens yet it has been proven that embedding Data Fork Fonts (dfont) instead of TrueType Fonts (ttf) gives a better result on a Mac.
To make changes to a font outline or format you might want to check out FontForge.
For those of you willing to play around there are 2 different Flash sources:
Your comments and discoveries are most welcome.
Related resources:


14 Responses
i have a problem regarding font i am working on presentation in flash cs3 i have to use Frutiger bold italic font. i have installedthe font in font folder .but in flash that font is not appearing cud you help me i mean what may be the problem that font is not appearing in flash
Even though Frutiger is part of copyrighted Adobe FontFolio package, having restrictions on including the font outline in PDF files, you should be able to embed the font without an hassle in Flash.
Please make sure you embed correct character sets in respect to your locale. So if your language happens to be Sanskrit, Hindi, or some other Indian language you may want to select a Devanagari character set from the Character Embedding dialogue box in Flash.
I do use embedfonts in AS 3.0. The funny thing is a string – “Iamtwo” works fine. But a string – “Iam20345″ or “345″ displays Iam or nothing. The reason is simple hasGlyph has failed for the latter two cases. Now how do I fix this. And what is going on?
ajjo, are you sure you checked Numerals for inclusion? You’ve got to hold down Ctrl (Cmd in Mac) to select multiple values in Character embedding…
[...] Exactly because embedding fonts in Flash CS3 is seriously problematic and buggy, the menu doesn’t have embedded fonts. The chosen font follows [...]
[...] 8 ] More rants on Flash CS3′s lack of proper embedding, in particular with pixel fonts..Flash CS3 renames them for [...]
I recently upgraded to Flash CS3 from 8 and now when I publish a swf which is then embedded into a Director 8.5 cast member, the embedded fonts do not show up in the Director projector. The fonts are fine when viewing the swf.
If I set a text field to device fonts they do show in the projector, but this is no good as I need to embed the custom fonts! I have also tried every antialising setting with no luck.
I haven’t changed anything else ie. the Flash code and Director code hasn’t changed. Just the version of Flash.
Any tips?
This is a really interesting article – I have added your blog to my favourites i really like it, keep up the good work!
Hi flash tekkie, thanks for you comment on my font-embedding tut and your FYI. but unfortunately I can’t find a workaround here like you said. Did you copy the wrong url?
It’s already a workaround in itself as the embedding in ActionScript fails for the unicode ranges.
Interesting article, thanks for the information.
Font ‘Arial’ successfully embedded (embedded fonts: Arial)!
Font is incapable of displaying ‘Text: /šššžžžžžžž/öüäõ/фваыафиывапывап/’
Is the above AS3_test.fla work for you?
Anyway. The interesting thing is that if you put a dynamic text filed with special characters to the stage and click embed all, its ok. But if you add this font to the library and check “Export for actionscript” special characters disappear.
[...] – The problem described http://tekkie.flashbit.net/flash/embedding-fonts-in-flash-cs3 [...]
does it work in CS4 as well?