Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

small phi font problem

25 views
Skip to first unread message

da...@alzt.tau.ac.il

unread,
Feb 2, 2008, 8:00:19 AM2/2/08
to dev-tec...@lists.mozilla.org
I am working on a courseware of calculus for university students,
based on xml technique, including mathml.

In math the common curly small letter phi font is extensively used as
the polar angle in some coordinate systems (for example -
cylindrical), and another one - a miniaturized capital phi is used for
different purposes. It is imperative that any browser, in any
appropriate operating systems, uses the same rule for rendering these
fonts. That way a user can interchange the browsers without affecting
the rendering.

With the increasing browsers' support of mathml, and with the
different interpretations of the two fonts of the small Greek letter
phi, a problem arises. Details about the fonts and their
interpretations by the mathml rendering software are shown in the next
snapshot (a gif file):
"http://alzt.tau.ac.il/~dagan/mathanimated/phifont/phi.gif".
Any one can check how his own browser renders the small phi by applying
"http://alzt.tau.ac.il/~dagan/mathanimated/phifont/phiFont.xhtml".

The identical way of rendering the fonts was achieved so far by IE +
MathPlayer, and by the FireFox-browser version 2. For some obscure
(to me) reasons the rendering of the phi fonts in a text and in a
mathml expression are inverted there, but since the same rule is
applied by the both, the interchangeability between the browsers is
kept.

One could expect that the browsers with native mathml support in their
beta stage of development - FireFox version 3 and Opera version 9.5 -
will continue to follow the same rule for rendering the phi fonts, in
order to be interchangeable among themselves and with respect to the
already existing ones. Unfortunately this is not the case at present,
as seen in the above mentioned snapshot
"http://alzt.tau.ac.il/~dagan/mathanimated/phifont/phi.gif".
Even the same browser acts differently in different platforms (Mac and
Windows).

If FireFox will return and readopt its own rule, used in FireFox
version 2, it is conceivable that Opera will follow, and the problem
will be solved. I avoided to file a bug-report on this subject, it
seems to me that an email to this list is more appropriate.

Cheers, Samy

Justu...@piater.name

unread,
Feb 2, 2008, 9:40:51 AM2/2/08
to da...@alzt.tau.ac.il, dev-tec...@lists.mozilla.org
The Plane-1 Unicode math range provides separate code points for the
two different versions of phi.

See my test page that displays them side by side:
http://www.montefiore.ulg.ac.be/~piater/test/phi.xhtml

Now all you (and your users) need is a font that provides the math
range :-) (but you need that anyway for standard-conforming rendering
of MathML). The STIX fonts already work with Firefox 2, and will be
the default for Firefox 3.

Justus

da...@alzt.tau.ac.il

unread,
Feb 2, 2008, 10:58:16 AM2/2/08
to Justu...@piater.name, dev-tec...@lists.mozilla.org
Hi Justus,

I know that there are two separate font versions of small phi.
Probably I did not make myself clear to you: in order to be consistent
with mathml rendered by Firefox 2, one have to switch between the the
two fonts used within a text and used in a mathml expression. Cheers,
Samy

Eduardo Tabacman

unread,
Feb 2, 2008, 2:01:30 PM2/2/08
to da...@alzt.tau.ac.il, dev-tec...@lists.mozilla.org, Justu...@piater.name
I don't know anything about the Mozilla implementation of this, but I'm
sure it relates to the fonts that are being used.

The glyphs for the two versions of phi (0x3c6 and 0x3d5) were swapped at
some point by the unicode specs;
i.e., they used to be one way (curly for 3d5, straight for 3c6), and
after a certain version of unicode (3.0?), they were swapped.
Therefore, there are many fonts that agree with the older glyphs, and
many others that agree with the new (and now correct) glyphs.

If one want to have the phis always display correctly, there should be
some ad-hoc code for dealing with their display, font-by-font.

eduardo

> _______________________________________________
> dev-tech-mathml mailing list
> dev-tec...@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-tech-mathml
>

William F Hammond

unread,
Feb 2, 2008, 2:58:36 PM2/2/08
to dev-tec...@lists.mozilla.org
Others wrote:

> ... there are two separate font versions of small phi.

> Probably I did not make myself clear to you: in order to be consistent
> with mathml rendered by Firefox 2, one have to switch between the the
> two fonts used within a text and used in a mathml expression. Cheers,

> ...


>> The Plane-1 Unicode math range provides separate code points for the
>> two different versions of phi.
>>
>> See my test page that displays them side by side:
>> http://www.montefiore.ulg.ac.be/~piater/test/phi.xhtml

I suppose most of us interested in math know the LaTeX names
\phi (straight) and \varphi (curly).

The current (version 2) xhtml+mathml dtd flags U-03C6 as varphi
(a name from LaTeX) and U-03D5 as straightphi. Those characters
display in my -u8 xterm as the DTD indicates and in a way
that is consistent with the "stixgeneral" beta font.

However, their display in mathml segments by Firefox 2 with pre-
stixbeta Mozilla-recommended fonts, both in linux and windows, has
always been reversed for me. (One of those old fonts must have it
wrong.)

The page cited by Justus uses plane 1: first U-1D711 (appearing as
varphi in my FF2) and second U-1D719 (appearing as straight phi in my
FF2).

Question 1. Why use the plane 1 versions rather than U-03C6 and
U-03D5? Will the version 3 DTD reflect this change?

Question 2. Is there a reasonable way for a Firefox user to
determine what font provides the glyph under the mouse in
her display?

Thanks.

-- Bill


da...@alzt.tau.ac.il

unread,
Feb 4, 2008, 7:42:09 AM2/4/08
to
Hi Eduardo,
Your information was very valuable. I understand now how come there
are two switched renderings of the phi fonts. Assuming that all the
the browsers use the new unicode specification (curly - &#x3c6,
straight - &#x3d5) for embeding in a text (not mathml), then all
depends of the fonts used by mathml.
Cheers, Samy

da...@alzt.tau.ac.il

unread,
Feb 4, 2008, 8:33:01 AM2/4/08
to
Hi Bill,

On Feb 2, 9:58 pm, William F Hammond <hamm...@csc.albany.edu> wrote:
>
> I suppose most of us interested in math know the LaTeX names
> \phi (straight) and \varphi (curly).
>
> The current (version 2) xhtml+mathml dtd flags U-03C6 as varphi
> (a name from LaTeX) and U-03D5 as straightphi.  Those characters
> display in my -u8 xterm as the DTD indicates and in a way
> that is consistent with the "stixgeneral" beta font.
>
> However, their display in mathml segments by Firefox 2 with pre-
> stixbeta Mozilla-recommended fonts, both in linux and windows, has
> always been reversed for me.  (One of those old fonts must have it
> wrong.)
>

> Question 1.  Why use the plane 1 versions rather than U-03C6 and
> U-03D5?  Will the version 3 DTD reflect this change?
>

Since I am using mathml generated by MathType (Design Science) with
swapped phi fonts and Firefox 2 used to swap them again for mathml
(before the STIX fonts), I've got everything right. But I agree, that
using the same convention for embed phi font in a text and for mathml
expressions does make more sense.

One has only to make sure that this convention will be adapted by
other browsers with mathml support, as Opera (Firefox 3 will take over
Firefox 1). IE and MathPlayer should probably have to make some
changes.

>
> Question 2.  Is there a reasonable way for a Firefox user to
> determine what font provides the glyph under the mouse in
> her display?

I was thinking that the browser could easily swap among the glyphs for
a mathml expressions only, by using CSS or other means.

I am still puzzled why FireFox 3, using the same STIX fonts, renders
the phi differently on Windows and on Mac ?

Cheers, Samy


David Carlisle

unread,
Feb 4, 2008, 9:19:29 AM2/4/08
to da...@alzt.tau.ac.il, dev-tec...@lists.mozilla.org

This is a problem also for entity definitions, especially for HTML
alignment, see

http://www.w3.org/TR/xml-entity-names/#diff-mathml2


David

________________________________________________________________________
The Numerical Algorithms Group Ltd is a company registered in England
and Wales with company number 1249803. The registered office is:
Wilkinson House, Jordan Hill Road, Oxford OX2 8DR, United Kingdom.

This e-mail has been scanned for all viruses by Star. The service is
powered by MessageLabs.
________________________________________________________________________

da...@alzt.tau.ac.il

unread,
Feb 9, 2008, 8:24:34 AM2/9/08
to
I am trying to summarize the small-phi font problem, as it appears to
me, from the exchange of emails by MathML users of this list,
who helped me to understand and to crystalize the problem.

1. There are two small-phi fonts that are used for different purposes
in
math:
a) curly small letter phi font (known from Latex as varphi)
b) a miniaturized capital phi (known from Latex as straightphi)

2. According to the more recent definition of Unicode (see e.g.
"http://www.w3.org/TR/xml-entity-names/#diff-mathml2")
&#x3C6; (&#966;) corresponds to the above 1a,
and &#x3D5; (&#981;) corresponds to the above 1b.

3. It is imperative that all browsers, in any appropriate operating
system,
be compatible, and use the same rule for rendering these fonts.

4. It is natural to use the Unicode rule (point 2 above), which is
already
adopted for Windows by Firefox 3b (Minefield trunk).
It should be applied also for other platforms (e.g. Mac).

Did I miss or misinterpret something?
Does someone know what rule is applied for Unix, or Linux?

Thanks, Samy

Karl Tomlinson

unread,
Feb 10, 2008, 6:22:06 PM2/10/08
to
da...@alzt.tau.ac.il writes:

> I am trying to summarize the small-phi font problem, as it appears to
> me, from the exchange of emails by MathML users of this list,
> who helped me to understand and to crystalize the problem.
>
> 1. There are two small-phi fonts that are used for different purposes
> in
> math:
> a) curly small letter phi font (known from Latex as varphi)
> b) a miniaturized capital phi (known from Latex as straightphi)
>
> 2. According to the more recent definition of Unicode (see e.g.
> "http://www.w3.org/TR/xml-entity-names/#diff-mathml2")
> &#x3C6; (&#966;) corresponds to the above 1a,
> and &#x3D5; (&#981;) corresponds to the above 1b.
>
> 3. It is imperative that all browsers, in any appropriate operating
> system,
> be compatible, and use the same rule for rendering these fonts.
>
> 4. It is natural to use the Unicode rule (point 2 above), which is
> already
> adopted for Windows by Firefox 3b (Minefield trunk).

Good summary.

> It should be applied also for other platforms (e.g. Mac).

It certainly should. That is a bug worth filing.

> Did I miss or misinterpret something?
> Does someone know what rule is applied for Unix, or Linux?

Linux with STIX fonts is the same as Windows with STIX fonts.
i.e. they follow the newer Unicode recommendation.

http://www.unicode.org/reports/tr25/#_Toc23

Karl Tomlinson

unread,
Feb 10, 2008, 6:29:14 PM2/10/08
to
On Sat, 02 Feb 2008 14:58:36 -0500, William F. Hammond wrote:

> Question 2. Is there a reasonable way for a Firefox user to
> determine what font provides the glyph under the mouse in
> her display?

Tools -> Dom Inspector will allow you to determine the requested
font family, but not the font actually have the glyph.

Select the node and select "Computed Style" from the menu next to
"Object".

The actual font should be the first family in the list that
provides a glyph for that code point. If none of those listed
provide the glyph, then a fallback font will be used; information
about that is not available.

William F Hammond

unread,
Feb 10, 2008, 11:57:50 PM2/10/08
to dev-tec...@lists.mozilla.org
Karl --

>> Question 2. Is there a reasonable way for a Firefox user to
>> determine what font provides the glyph under the mouse in
>> her display?
>
> Tools -> Dom Inspector will allow you to determine the requested
> font family, but not the font actually have the glyph.

Thanks again for all of your helpful answers.

I don't see the dom inspector in the menus of Firefox 2.0.0.12 for
Windows. Is it there?


-- Bill

Karl Tomlinson

unread,
Mar 4, 2008, 3:10:19 PM3/4/08
to
On Sun, 10 Feb 2008 23:57:50 -0500, William F. Hammond wrote:

> I don't see the dom inspector in the menus of Firefox 2.0.0.12 for
> Windows. Is it there?

Looks like it used to be an option at install time.
AFAIK this is the only way to get the DOM Inspector for FF2.

Now it available as an extension for Minefield builds:

https://addons.mozilla.org/en-US/firefox/addon/6622

https://bugzilla.mozilla.org/show_bug.cgi?id=339229

0 new messages