Reputation: 36
I get the following warning when I run my application:
warning: incompatible embedded font 'Arial' specified for spark.components::Label (Label104) . This component requires that the embedded font be declared with embedAsCff=true.
The application I am working on is a mix of Halo and Sparks components as I am migrating it to Flex 4. The text that is showing in the text fields is defaulting the systems serif font.
There are a few problems with this warning.
1) I am not embedding any fonts in the application. I am not even assigning the Arial font to any of the components.
2) If I check the "Use Flash Text Engine in MX components", then all the text fields in the app throw the warning. Not just the sparks text fields.
Why does flex 4 think that I am using an embedded font with the sparks components? Is there any way to get around this warning and have the text fields use a non embedded font?
Upvotes: 0
Views: 2846
Reputation: 8050
It looks like the FlexWiz blog ran into this issue as well.
Embedded fonts problems
Now that my project compiles and runs, I notice that the fonts don’t look right. However, this time the nice folks at Adobe provided us with the following warning:
warning: incompatible embedded font 'ArialFont' specified for mx.controls::UITextField (UITextField36). This component requires that the embedded font be declared with embedAsCff=false.
Well, as it turns out, the new SDK now assigns two different types of embedded fonts: CFF embedded and non-CFF embedded. The CFF is used exclusively by spark components, while the mx components can only use non-CFF – too bad, since it practically means you cannot share styles between, say, spark and halo labels and text fields like I did.
To fix this, you’d have to define each of your embedded fonts twice: one instance for spark, and another instance for halo.. oops, I mean mx. In the mx font embed, set embedAsCFF to ’false’, and then create styles for both types and use them from their corresponding components. There is a detailed explanation with code samples on the Adobe web site.
Upvotes: 2