Re: Displaying chinese ideographs in svg page with Javascript and unicode

Hi, Fred-

First, I want to remind you that www-svg is not a forum for asking
development questions about SVG.  Please use the SVG-Developers Yahoo
group for that.  This list is for questions or comments regarding the
specification itself.

As to your problem, I suspect that part of the issue may be due to a
faulty content-type configuration on your server, for referencing the
SVG file in HTML.

Another problem may be the character encoding of your file itself, as
Fred already pointed out.

Yet another thing to check is that the system you are viewing the file
on has a Unicode-capable font.  I noticed you specified the font-family
"SimSun" in your file... maybe that wasn't available, and the fallback
wasn't working for some reason?

I made a little test [1][2], and the SVG worked just fine on Firefox and
WebKit/Safari, and all but the raw glyph worked on Opera.  I'm on a Mac,
so I didn't test IE+ASV.

[1] http://www.schepers.cc/svg/unicode.html
[2] http://www.schepers.cc/svg/unicode.html

I hope that helps-
-Doug


Fulio Pen wrote (on 9/14/08 8:37 PM):
> Hi, Fred:
> 
> Thanks for your message. I saved the attached svg file to your email,
> embedded it in an html file, and uploaded both to my web site. Their
> URLs are as follows:
> 
> www.pinyinology.com/test/tree_fred.svg
> <http://www.pinyinology.com/test/tree_fred.svg>
> www.pinyinology.com/test/tree_fred.html
> <http://www.pinyinology.com/test/tree_fred.html>
> 
> Open these files online, you will see the html one is not rendered on
> all IE, FF and Opera browsers.  The svg page is not rendered on IE and
> FF, and poorly on Opera.  In short, the svg does not render Chinese
> characters independently online. 
> 
> Thanks again.
> Fulio
> www-svg@w3.org
> www-svg@w3.org
> 

Received on Monday, 15 September 2008 04:58:56 UTC