Reputation: 11
I know this is similar to an already asked question, but I would love to get some more detailed help on how the outcome was achieved.
I have a website with SWF animations of automotive systems. Each animation has labels naming the parts, action buttons to show failures, and links to other animations. The text for each label is dynamic, with the label being pulled from an XML file. We allow the user the option of changing the language, and currently have successfully used English/French/Spanish (all left to right) and Hebrew (right to left).
We are trying to add Traditional Chinese for a user in Taiwan, and are having difficulty getting the characters to display. We can make it work if we embed the font file into the SWF, but the file size increases to a point that it is not practical to do. I want to use the "Device Font" option, so that we can enter the Chinese text into our XML file, and then the SWF will use the font file from the end users computer to display the characters, but if I change the text property to "Device Font" it makes all the label text in the boxes disappear, no matter what language I select. If I leave the box set to "Anti-alias", the other languages display correctly.
The XML file contains this for the Chinese language label: and this for the English Language label:
The encoding of the XML file is UTF-8.
Is there something I am forgetting to do? Any help will be greatly appreciated.
Upvotes: 0
Views: 2065
Reputation: 22604
UTF-8 encoding will only work properly with unicode fonts. If you use device fonts, you will have to use the local code page and character encoding. I would advise against this, because you can never ever be sure it will work for everyone. UTF-8 is a much better choice.
So, you should use UTF-8 and embedded fonts, but do some of the following:
Upvotes: 1