0

I'm having a hard time trying to limit the size of the app by reducing the unicode range of my fonts.

I've tried several different combinations, the error is the same no matter what range I put there:

-invalid Unicode range '005A'

Where 005A can be anything, if I do this:

unicodeRange: U+0020-007E;

The error is this: -invalid Unicode range '007E'

I've tried different fonts, Arial, Helvetica, Century... Same error in everyone, all the unicode ranges throw errors in the CSS file.

Any ideas what could be wrong? I've read the documentation from Adobe, not sure what else to do.

hippietrail
  • 15,848
  • 18
  • 99
  • 158
Artemix
  • 8,497
  • 14
  • 48
  • 75

1 Answers1

2

Here is a CSS file as example - it works well for me in an iOS/Android card game app (where I need card suits and cyrillic characters):

@namespace s "library://ns.adobe.com/flex/spark";
@namespace mx "library://ns.adobe.com/flex/mx";

@font-face { 
    src: url("/assets/fonts/arial.ttf"); 
    fontFamily: embFont;
    embedAsCFF: false; /* required for StyleableTextField */
    unicodeRange:
        U+0020-U+0040, /* Punctuation, Numbers */
        U+2660-U+2666, /* Card suits */
        U+0041-U+005A, /* Upper-Case A-Z */
        U+0061-U+007A, /* Lower-Case a-z */
        U+0410-U+0451; /* Cyrillic */   
}

s|LabelItemRenderer {
    fontFamily: embFont;
}
Alexander Farber
  • 21,519
  • 75
  • 241
  • 416
  • 1
    Thanks!, your example worked perfectly, mine didn't work because of the format Adobe used in their example here: http://help.adobe.com/en_US/flex/using/WS2db454920e96a9e51e63e3d11c0bf69084-7e04.html If you take a look, you will notice that instead of: U+0041-U+005A they used: U+0041-005A That threw an error. – Artemix Aug 28 '14 at 14:05