• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
Locked
0

Not all chinese characters display correctly with non-embedded text

Enthusiast ,
Jan 21, 2010 Jan 21, 2010

Copy link to clipboard

Copied

Hi all,

  I've updated to the last beta 2 of Flash Player 10.1 (10,1,51,66) and compiled this simple Flex application to illustrate the fact that not all chinese characters can be displayed correctly with non-embedded text (device font).

<?xml version="1.0" encoding="utf-8"?>

<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"

               xmlns:s="library://ns.adobe.com/flex/spark"

               xmlns:mx="library://ns.adobe.com/flex/halo"

               minWidth="1024" minHeight="768"

               creationComplete="resourceManager.localeChain = ['zh_CN'];"

               layout="{new VerticalLayout()}">           

    <fx:Script>

        <![CDATA[

            import spark.layouts.VerticalLayout;

        ]]>

    </fx:Script>

    <s:Label text="伜-伞伟传伡伢伣伤伥伦伧伨伩伪伫伬伭-伝">

    </s:Label>

    <mx:Label text="伜-伞伟传伡伢伣伤伥伦伧伨伩伪伫伬伭-伝"/>       

</s:Application>

  Notice that characters from the Unicode range 0x4F1E .. 0x4А2D are not displayed within <s:Label> component that uses Flash Text Engine (FTE) by default to display the text, but at the same time those characters display just fine within older <mx:Label> component that relies on flash.text.TextField instance to render the text.

TOPICS
Text layout framework

Views

8.5K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Deleted User
Jan 27, 2010 Jan 27, 2010

Adding Arial Unicode MS to your font family list is probably the way to go - and it's likely that a substantial portion of the 37.5% that do not have that font and are interested in viewing Chinese text will have East Asian language support enabled. So they would be able to view the text in SimSun.

Votes

Translate

Translate
Guest
Jan 21, 2010 Jan 21, 2010

Copy link to clipboard

Copied

When I compile your code with a relatively recent Flash Builder 4.0 install and open in 10.1 beta 2, I see both labels with the same glyphs. Could you give a picture of your results?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Jan 22, 2010 Jan 22, 2010

Copy link to clipboard

Copied

chinese_characters.jpg

Here the screenshot of what I see, I am running Windows XP, Flash Player 10,1,51,66 (debug), Internet Explorer 6.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Jan 22, 2010 Jan 22, 2010

Copy link to clipboard

Copied

OK - I can see the problem in XP. In Vista, Win 7 and the Mac it renders correctly. I'm asking around why font fallback isn't working in this case for XP.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Jan 22, 2010 Jan 22, 2010

Copy link to clipboard

Copied

Do you have simsun.ttf in your C:\WINDOWS\fonts directory? The new FTE font fallback feature expects to be able to use that font, which appears on the list of fonts installed in XP here: http://www.microsoft.com/typography/fonts/winxp.htm.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Jan 25, 2010 Jan 25, 2010

Copy link to clipboard

Copied

Hi Alan,

  You are right, my install of Windows XP English Service Pack 3 is missing the "simsun.ttc" font.

   I think this font will only be installed when I manually turn on the support for East Asian languages in "Control Panel " > "Regional And Language Options".

  When I refer to the more recent version of the page "Fonts supplied with* Windows XP"  http://www.microsoft.com/typography/Fonts/product.aspx?PID=135, I can clearly see the note "The installation of any particular font may be dependent on the installation options that are selected."

   I've added this missing font "simsun.ttc" manually and all chinese symbols begin to be visible in FTE  ==  FTE font fallback feature is working  when this font is available at the system. 

    So my question now is - can FTE font fallback feature for Chinese language depend on some other font rather then "simsun.ttc" which is included into standard install Windows XP English version? May be in a future?

    If not, we have no other option rather then to embed "simsunttc" font.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Jan 25, 2010 Jan 25, 2010

Copy link to clipboard

Copied

I've forwarded this problem to the person in control of the Player fallback list. He's investigating whether we could use one of the fonts in the minimal XP install instead of simsun.ttf.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Jan 26, 2010 Jan 26, 2010

Copy link to clipboard

Copied

It turns out that the minimum XP install does not include any fonts that we could use to display those glyphs. My own XP install included Office, so it had Arial Unicode MS, which looks like the only font the FP9 text could have been drawn with.

Could you post a list of your fonts (and their sizes)? The result of a "dir" command on your c:\Windows\Fonts directory would give us the information we need.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Jan 27, 2010 Jan 27, 2010

Copy link to clipboard

Copied

    OK, did not know that "Arial Unicode MS" font is only distributed with Microsoft Office, was looking into relying on this font in case if "simsun.ttc" font is not available at the user's system, by using the following:

<?xml version="1.0" encoding="utf-8"?> <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"                xmlns:s="library://ns.adobe.com/flex/spark"                xmlns:mx="library://ns.adobe.com/flex/mx"                minWidth="1024" minHeight="768"                creationComplete="resourceManager.localeChain = ['zh_CN']"                layout="{new VerticalLayout()}">                    <fx:Style>         @namespace s "library://ns.adobe.com/flex/spark";         @namespace mx "library://ns.adobe.com/flex/halo";                 s|Label {             fontFamily: "Arial Unicode MS, SimSun, Arial";                     }                              </fx:Style>        <fx:Script>         <![CDATA[             import spark.layouts.VerticalLayout;         ]]>     </fx:Script>     <s:Label id="sparkLabel" text="伜-伞伟传伡伢伣伤伥伦伧伨伩伪伫伬伭-伝"/>    </s:Application>  

Tough decision ahead, but accordingly to  the survey at codestyle.org (2000 participants from 2007 year and onwards), Arial Unicode MS is present at 62.53%% system surveyed.

ps

   My current install of Windows XP already includes the install of Microsoft Office 2007 and I've also enabled/disabled the support of East Asian languages, thus the content of  my "fonts" folder differs now significantly from "clean" Windows XP install version.

Nevertheless I found the page with comprehensive lists of standard fonts installed with different releases of Windows that looks viable here:  http://www.kayskreations.net/fonts/fonttb.html

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Jan 27, 2010 Jan 27, 2010

Copy link to clipboard

Copied

Adding Arial Unicode MS to your font family list is probably the way to go - and it's likely that a substantial portion of the 37.5% that do not have that font and are interested in viewing Chinese text will have East Asian language support enabled. So they would be able to view the text in SimSun.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 03, 2010 Feb 03, 2010

Copy link to clipboard

Copied

Another thing to check is to make sure you have supplemental language support installed. Go to Control Panel > Regional and Language Options > Languages (tab) and check the box for Install files for East Asian languages. Hope this helps.

Marc

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Feb 03, 2010 Feb 03, 2010

Copy link to clipboard

Copied

LATEST

No, I do not have installed support for East Asian languages at my Windows XP install, that's a problem

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines