I have an application developed for AIR. When I compile it without the fonts that I need to embed it is compiled without problems when I add the Embed tags then it compiles but when it is running it can not be used, the input text fields cannot be accessed.
Has anybody encountered this problem? What could be the possible reasons?
Here is an example of how I embed the fonts.
[Embed(systemFont="FreeSans", embedAsCFF='false', fontName="FreeSansEmbed", mimeType="application/x-font")]
private var freeSansFont:Class;
Is it possible that Flash Pro has some parameters that limit the amount of time or size of a file or the compilation in some other way and that the animation with the fonts is too big? If so is there a place where I can change those parameters?
I tried this a long time ago and had some success (but I did update to 2.7, then to 3.0, not straight to 3.0, not sure if it matters):
You can change the Java heap size allocation and increasing the memory available to it often allows compiles to happen. For Flash CS5.0 you'd find that setting in this file:
C:\Users\[YOUR USER]\AppData\Local\Adobe\Flash CS5\en_US\Configuration\ActionScript 3.0\jvm.ini
I bolded en_US as that's obviously US English, change to your langauge as necessary.
Adjust the value -Xmx128m to -Xmx256m (128mb -> 256mb) and try that. You can also try increasing it to 512m but I've had some issues starting the java virtual machine using that much ram (not sure why). This will increase the amount of ram the compile process is allowed to use.
It helps to a limit but I'm glad it solves your problem. The issue comes when too many assets are in a single SWF. Keep things separated so they're compiled separately and I've had no issue like that.
Europe, Middle East and Africa