By default, mx:Text wants embedAsCFF=false. Unless you are using FTE in MX
Hi Flex harUI,
thanks for answering.
I've changed the embedAsCFF property to false, but still get no data.Though I've created a new project containing only the .css file and a mx:Text control, and it work OK.
Looking further than the mx:Text control and the .css file, maybe the issue lies in the parameters around this control? The mx:Text control is located in an item renderer, and its being called by a custom skin (being called by a custom component...) - would this cause an error with the referencing of embed fonts in .css files?
Make sure the mx:Text's text property is actually being set to something,
and has a reasonable size.
...and it has a different color than the background
<?xml version="1.0" encoding="utf-8"?>
<s:Group width="100%" height="20">
<s:HorizontalLayout verticalAlign="middle" />
<s:Label text="label:" width="100" textAlign="right" fontSize="14"/>
<mx:Text text="text" width="100%" color="#000000" fontSize="1" />
text values for label and text controls have been statically set while I'm trying to get this working. I've also explicitely set the color and size, though these values should be the default values nonetheless. There is a background set on the skin calling this itemRenderer, but its a light grey - the black text should still be visible.
Your font size is 1. We don't have built-in font size lookups like HTML.
Originally this wasn't working because I was defining the font-family in many different .swcs, because I want all my components to have the same font. Changing the config of the file (to embedAsCFF = false) would cause problems when running because i had two difference configs for the same font family (one where the embed was false and another where the embed was true from another defaults.css being called by another component).
Renaming my font-family to "sparkFont" and "mxFont" to take into account the embedAsCFF difference should resolve this issue.
Thanks for your help.