If an HTML font statement specifies the TrueType font Wingdings, only
alphabetical characters display, although the font size and color
renders correctly. My other TrueType fonts display as expected.
As a test, I created a new HTML page with no content but some text
inside font tags. Same problem. Netscape and IE render the Wingdings
properly.
Is this a known problem? Are there any other fonts that I should avoid
putting in Web pages because of problems with Opera?
Thanks for any thoughts on this.
--
Doug Mackie
Netscape (I presume you mean 4.something) and IE render the page in
contravention to standards released over 5 years ago. They use legacy
coding dating from times when the US and Europe were the sole focus for
software and operating system developers.
The unicode standard is helping to make the web more workable for the
billions of people who use writing systems other than what is commonly
called the latin alphabet. Unicode-compliant browsers must present the
characters contained in the source.
For example:
If you write
<P><font face="wingdings">J</font></p> and expect to see a smiley face,
you are wrong.
A conformant browser should say that a capital letter J was requested and
must be displayed.
Remember that the (deprecated) presentational markup <font face> is at
best a suggestion, and in many cases cannot be acted upon:
1) There are operating systems for which there has never been a font
called wingdings.
2) Even on Windows, the user may not have it installed.
3) The user might be using a device which has no concept of fonts:
A speech based device, brailler, 80x20 cellphone display, Teletype text
screen, spider or other robot.
The correct approach is to use an entity. In Unicode the Smiley face
belongs to a section called Miscellaneous Symbols.
You can place it on a page thus:
<P>&263A;</p> (hexadecimal notation)
<P>☺</p> (decimal notation)
For a subset of commonly used glyphs (a couple of hundred of the tens of
thousands) there are named entities.
For example: ♠ = &2660; the black spades symbol from cards.
Where they exist it is better to use the character entities, since
browser support for them is better.
References: http://www.unicode.org
http://www.alanwood.net/unicode/
> Is this a known problem? Are there any other fonts that I should avoid
> putting in Web pages because of problems with Opera?
Please see the threads archived at:
http://groups.google.com/groups?threadm=9td69d%24iuk%241%40mail.opera.no
http://groups.google.com/groups?threadm=3c9f3676.14118870%40news.opera.no
for an insight into why this is happening.
--
\\//
Peter, developer / utvecklare / utvikler / Entwickler, Opera Software
The opinions expressed are my own, and not those of my employer.
Please reply only by follow-ups in the newsgroup.
[...]
An excellent explanation, you just have a syntax error for hexadecimal
character references [1]:
> The correct approach is to use an entity. In Unicode the Smiley face
> belongs to a section called Miscellaneous Symbols.
> You can place it on a page thus:
> <P>&263A;</p> (hexadecimal notation)
This should be: <P>☺</p> ("#x" denotes hexadecimal, like "#" decimal)
> <P>☺</p> (decimal notation)
This is just fine.
[1] <http://www.w3.org/TR/2000/REC-xml-20001006#sec-references>
Jonny Axelsson,
Documentation,
Opera Software.
Many thanks for your prompt and detailed explanation - I obviously need
to learn about Unicode!
And thanks to Jonny Axelsson and Peter Karlsson for their additions and
links.
--
Doug Mackie
"Richard Grevers" <newsfe...@dramatic.co.nz> wrote in message
news:MPG.17c1be2c5...@news.opera.com...