* Incorrect rendering of * with UTF math fonts @ 2012-02-22 19:52 Aditya Mahajan 2012-02-22 20:31 ` Otared Kavian 2012-02-22 21:53 ` Khaled Hosny 0 siblings, 2 replies; 7+ messages in thread From: Aditya Mahajan @ 2012-02-22 19:52 UTC (permalink / raw) To: mailing list for ConTeXt users Hi, Using * in superscripts gives wrong glyph size and spacing. For example, with LM math everyhing looks fine: \starttext $x^*$ vs $x^{\ast}$ \stoptext With Cambria, the result is OK (but you can still see the differences in the spacing of * in x^*) \usemodule[simplefonts] \setmathfont[Cambria] \starttext $x^*$ vs $x^{\ast}$ \stoptext With Neo Euler, $x^*$ look really bad. \usemodule[simplefonts] \setmathfont[Cambria] \starttext $x^*$ vs $x^{\ast}$ \stoptext I cannot figure out why this is happening. It definitely looks like a bug at the context end rather than a bug with the fonts. Aditya ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Incorrect rendering of * with UTF math fonts 2012-02-22 19:52 Incorrect rendering of * with UTF math fonts Aditya Mahajan @ 2012-02-22 20:31 ` Otared Kavian 2012-02-22 20:47 ` Wolfgang Schuster 2012-02-22 21:53 ` Khaled Hosny 1 sibling, 1 reply; 7+ messages in thread From: Otared Kavian @ 2012-02-22 20:31 UTC (permalink / raw) To: mailing list for ConTeXt users Hi Aditya, I tried your code: as you say with LM there is no problem, but with the simplefonts module nothing i stypeset since I get an error message: <to be read again> \3>simplefonts:1-12pt-mm-mr--3 \font_helpers_preset_math_family_indeed ...csname \scriptfont #1\csname \??f... \font_helpers_set_math_family ...amily_indeed #1#2 \else \font_helpers_set_ma... \font_helpers_bidirectional_mathstrategy_nop ...r \textfont \c_font_fam_mr_r... <inserted text> ...bidirectional_mathstrategy_nop \fi \font_helpers_apply_co... \font_helpers_synchronize_math ...math_strategies \fi ... This is with ConTeXt ver: 2012.02.21 00:51 MKIV. Best regards: OK On 22 févr. 2012, at 20:52, Aditya Mahajan wrote: > Hi, > > Using * in superscripts gives wrong glyph size and spacing. > > For example, with LM math everyhing looks fine: > > \starttext > $x^*$ vs $x^{\ast}$ > \stoptext > > With Cambria, the result is OK (but you can still see the differences in the spacing of * in x^*) > > \usemodule[simplefonts] > \setmathfont[Cambria] > \starttext > $x^*$ vs $x^{\ast}$ > \stoptext > > With Neo Euler, $x^*$ look really bad. > > \usemodule[simplefonts] > \setmathfont[Cambria] > \starttext > $x^*$ vs $x^{\ast}$ > \stoptext > > I cannot figure out why this is happening. It definitely looks like a bug at the context end rather than a bug with the fonts. > > Aditya > > ___________________________________________________________________________________ > If your question is of interest to others as well, please add an entry to the Wiki! > > maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context > webpage : http://www.pragma-ade.nl / http://tex.aanhet.net > archive : http://foundry.supelec.fr/projects/contextrev/ > wiki : http://contextgarden.net > ___________________________________________________________________________________ ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Incorrect rendering of * with UTF math fonts 2012-02-22 20:31 ` Otared Kavian @ 2012-02-22 20:47 ` Wolfgang Schuster 2012-02-22 21:28 ` Otared Kavian 0 siblings, 1 reply; 7+ messages in thread From: Wolfgang Schuster @ 2012-02-22 20:47 UTC (permalink / raw) To: mailing list for ConTeXt users Am 22.02.2012 um 21:31 schrieb Otared Kavian: > Hi Aditya, > > I tried your code: as you say with LM there is no problem, but with the simplefonts module nothing i stypeset since I get an error message: Do you have Cambria? Wolfgang ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Incorrect rendering of * with UTF math fonts 2012-02-22 20:47 ` Wolfgang Schuster @ 2012-02-22 21:28 ` Otared Kavian 2012-02-22 21:35 ` Wolfgang Schuster 0 siblings, 1 reply; 7+ messages in thread From: Otared Kavian @ 2012-02-22 21:28 UTC (permalink / raw) To: mailing list for ConTeXt users Yes, I have it in /Library/Fonts/Microsoft/Cambria.ttf Maybe is it the wrong version? In my test files I have other instances where Cambria is used and correctly typeset, but with the new versions they don't typeset anymore. Best regards: OK On 22 févr. 2012, at 21:47, Wolfgang Schuster wrote: > > Am 22.02.2012 um 21:31 schrieb Otared Kavian: > >> Hi Aditya, >> >> I tried your code: as you say with LM there is no problem, but with the simplefonts module nothing i stypeset since I get an error message: > > Do you have Cambria? > > Wolfgang > ___________________________________________________________________________________ > If your question is of interest to others as well, please add an entry to the Wiki! > > maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context > webpage : http://www.pragma-ade.nl / http://tex.aanhet.net > archive : http://foundry.supelec.fr/projects/contextrev/ > wiki : http://contextgarden.net > ___________________________________________________________________________________ ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Incorrect rendering of * with UTF math fonts 2012-02-22 21:28 ` Otared Kavian @ 2012-02-22 21:35 ` Wolfgang Schuster 0 siblings, 0 replies; 7+ messages in thread From: Wolfgang Schuster @ 2012-02-22 21:35 UTC (permalink / raw) To: mailing list for ConTeXt users Am 22.02.2012 um 22:28 schrieb Otared Kavian: > Yes, I have it in > /Library/Fonts/Microsoft/Cambria.ttf > Maybe is it the wrong version? For math you need “Cambria Math.ttf” or “Cambria.ttc”. > In my test files I have other instances where Cambria is used and correctly typeset, but with the new versions they don't typeset anymore. Cambria works for me: \usemodule[simplefonts] \setmainfont[Cambria] \setmathfont[Cambria] \starttext \input knuth \startformula 1 + 1 = 2 \stopformula \stoptext Wolfgang ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Incorrect rendering of * with UTF math fonts 2012-02-22 19:52 Incorrect rendering of * with UTF math fonts Aditya Mahajan 2012-02-22 20:31 ` Otared Kavian @ 2012-02-22 21:53 ` Khaled Hosny 2012-02-22 22:22 ` Aditya Mahajan 1 sibling, 1 reply; 7+ messages in thread From: Khaled Hosny @ 2012-02-22 21:53 UTC (permalink / raw) To: mailing list for ConTeXt users On Wed, Feb 22, 2012 at 02:52:22PM -0500, Aditya Mahajan wrote: > Hi, > > Using * in superscripts gives wrong glyph size and spacing. > > For example, with LM math everyhing looks fine: > > \starttext > $x^*$ vs $x^{\ast}$ > \stoptext For me this is typeset using LM Type1 fonts, not the OpenType LM math font which explains why both are correct, after adding \setupbodyfont[modern] the first * is raised than the other but still readable. > With Cambria, the result is OK (but you can still see the > differences in the spacing of * in x^*) > > \usemodule[simplefonts] > \setmathfont[Cambria] > \starttext > $x^*$ vs $x^{\ast}$ > \stoptext > > With Neo Euler, $x^*$ look really bad. > > \usemodule[simplefonts] > \setmathfont[Cambria] > \starttext > $x^*$ vs $x^{\ast}$ > \stoptext > > I cannot figure out why this is happening. It definitely looks like > a bug at the context end rather than a bug with the fonts. It seems that * in math mode should map to U+2217 (which is what \ast maps to) and not the ASCII asterisk. Regards, Khaled ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Incorrect rendering of * with UTF math fonts 2012-02-22 21:53 ` Khaled Hosny @ 2012-02-22 22:22 ` Aditya Mahajan 0 siblings, 0 replies; 7+ messages in thread From: Aditya Mahajan @ 2012-02-22 22:22 UTC (permalink / raw) To: mailing list for ConTeXt users On Wed, 22 Feb 2012, Khaled Hosny wrote: > On Wed, Feb 22, 2012 at 02:52:22PM -0500, Aditya Mahajan wrote: >> Hi, >> >> Using * in superscripts gives wrong glyph size and spacing. >> >> For example, with LM math everyhing looks fine: >> >> \starttext >> $x^*$ vs $x^{\ast}$ >> \stoptext > > For me this is typeset using LM Type1 fonts, not the OpenType LM math > font which explains why both are correct, after adding > \setupbodyfont[modern] the first * is raised than the other but still > readable. > >> With Cambria, the result is OK (but you can still see the >> differences in the spacing of * in x^*) >> >> \usemodule[simplefonts] >> \setmathfont[Cambria] >> \starttext >> $x^*$ vs $x^{\ast}$ >> \stoptext >> >> With Neo Euler, $x^*$ look really bad. >> >> \usemodule[simplefonts] >> \setmathfont[Cambria] >> \starttext >> $x^*$ vs $x^{\ast}$ >> \stoptext >> >> I cannot figure out why this is happening. It definitely looks like >> a bug at the context end rather than a bug with the fonts. > > It seems that * in math mode should map to U+2217 (which is what \ast > maps to) and not the ASCII asterisk. Indeed. Making this change gives the correct result. @Hans, can you make the following change in char-def.lua --- char-def.old 2012-02-22 17:18:05.000000000 -0500 +++ char-def.lua 2012-02-22 17:19:06.000000000 -0500 @@ -382,8 +382,7 @@ description="ASTERISK", direction="on", linebreak="al", - mathclass="binary", - mathname="ast", + mathsymbol=0x2217, unicodeslot=0x002A, }, { Aditya ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ ^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2012-02-22 22:22 UTC | newest] Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2012-02-22 19:52 Incorrect rendering of * with UTF math fonts Aditya Mahajan 2012-02-22 20:31 ` Otared Kavian 2012-02-22 20:47 ` Wolfgang Schuster 2012-02-22 21:28 ` Otared Kavian 2012-02-22 21:35 ` Wolfgang Schuster 2012-02-22 21:53 ` Khaled Hosny 2012-02-22 22:22 ` Aditya Mahajan
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).