* Re: Math prime issues for some fonts
@ 2021-11-29 17:40 Jack Hill via ntg-context
0 siblings, 0 replies; 7+ messages in thread
From: Jack Hill via ntg-context @ 2021-11-29 17:40 UTC (permalink / raw)
To: ntg-context; +Cc: Jack Hill
[-- Attachment #1.1: Type: text/plain, Size: 1910 bytes --]
On Fri, 26 Nov 2021 at 11:28, Hans Hagen <j.hagen@xs4all.nl> wrote:
> So to summarize: with primes we have to deal with (1) frozen tex math
> expectations that won't change (although in context we're free to do
> so), which (2) have found their way in unicode, and (3) also in fonts
> due to the way traditional tex does it, and (4) with which we cannot
> deal with in the engine, so (5) we do it our own contexty way, in the
> hope that (6) in the end it all looks good and (7) also gives us some of
> the benefits that i don't even dare to bring up here in order not to
> make it sound more complex.
Thank you for the explanation. It's always interesting to hear about what
goes on under the hood.
> As a note: if you notice suboptional things in math fonts, don't
> hesitate to make a good minimal example and then ask Mikael to look into
> is because he deals with and coordinates the tuning of goodie files.
I have noticed that the top bar of square root signs don't seem to connect
properly with the angled part. This is visible with multiple fonts (some
make it more obvious than others) at various zoom levels (I'm using Okular
on Linux but other pdf viewers show the same - also on Windows). I've no
idea if this is visible in print since I don't print the pdfs. The effect
is also reproducible with the wiki version of context.
\starttext
\starttabulate[|l|c|]
\FL
\BC Font name \BC Math sqrt \NR
\ML
\NC Latin Modern Roman \NC \m{\sqrt{x}} \NR
\NC TeX Gyre Termes \NC \switchtobodyfont[termes] \m{\sqrt{x}} \NR
\NC TeX Gyre Pagella \NC \switchtobodyfont[pagella] \m{\sqrt{x}} \NR
\NC TeX Gyre Bonum \NC \switchtobodyfont[bonum] \m{\sqrt{x}} \NR
\NC TeX Gyre Schola \NC \switchtobodyfont[schola] \m{\sqrt{x}} \NR
\NC STIX Two \NC \switchtobodyfont[stixtwo] \m{\sqrt{x}} \NR
\BL
\stoptabulate
\stoptext
[-- Attachment #1.2: Type: text/html, Size: 2253 bytes --]
[-- Attachment #2: sqrt-schola-400%-zoom.png --]
[-- Type: image/png, Size: 2368 bytes --]
[-- Attachment #3: Type: text/plain, Size: 493 bytes --]
___________________________________________________________________________________
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://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Math prime issues for some fonts
2021-11-26 21:05 ` Mikael Sundqvist via ntg-context
@ 2021-11-27 12:28 ` Hans Hagen via ntg-context
0 siblings, 0 replies; 7+ messages in thread
From: Hans Hagen via ntg-context @ 2021-11-27 12:28 UTC (permalink / raw)
To: mailing list for ConTeXt users; +Cc: Hans Hagen
On 11/26/2021 10:05 PM, Mikael Sundqvist via ntg-context wrote:
> Hi Jack,
>
> I've been working with Hans on math in general and primes in
> particular in the last week. I do not understand all the details, but
> I think primes are handled differently now, and that one essentially
> need to have some tuning in goodie files (the reason is that they are
> done differently in different fonts, and that there was not simple
> one-fits-all solution). We have not touched eulernova yet.
It's not easy to explain in a few sentences so here we go.
In unicode, math is a script. There are plenty scripts supported and
unicode supports their properties. Unicode tries to avoid duplicates
but we have an latin A and a greek A, and we have plenty of nukta in
indic scripts even if the shapes are the same. In math however, for some
reason, we have ended up with some math code points being shared. So, we
don't have a small italic h (because every italic h is supposed to be
plank constant) and we don't have primes because minutes are primes.
Maybe today some strong arguing could avoid those anomalities but i fear
that we're stuck with it forever now (math legacy stuff etc).
This results of for instance holes in math alphabets (less such holes in
other scripts) that every application has to deal with and we end up
with symbols that depending on their usage need some interpretation and
handling. Btw, a side effect is that where an one can distinguish
between f as variable or function by using an indicator this is not
possible with h so in copy/paste or interpretation one has to guess what
it is. The same is true for prime like symbols: are they minutes or primes.
So, as the unicode slot for a prime is used for minutes (in text) the
symbols in a font ends up as superscript but in math text mode it would
not be in the right spot. Keep in mind that we have specific math fonts
so ther ei sno real reason for not making primes consistent in text,
script and scriptscript (ssty features): it simply is not done which in
turn is probably a side effect of cmr being uses as template even if for
other properties cmr fundamentally differs from open type math fonts.
Anyway, in the traditional tex approach to primes, the prime symbol is
taken from the script variant, where is has a different size (or not),
different boundingbox (or not) and/or is already raised (or not). Also,
in tex the ' is made into an "active in math mode" character (one of
few, an dit might even be that the reason for active math characters is
in primes) in order to ease input. It effectively being a macro means
that it can do some lookahead in order to (1) position itself as well as
(2) make it possible to be followed by a superscript and/or subscript.
And, because the way math is coded and dealt with in tex basically has
been chisseled in stone early after tex showed up, that situation is
supposed to be dealt with: a multi-purpose shape with somewhat weird
properties, parsing preferably in a robust way, positioning in a
superscript like position (before or after a script), i fpossible
intercepting interference etc. And ... all that is resembled in unicode
math as well as all these math fonts out there.
But it is not the way i want to deal with it in context, also because
there is even more involved (which i happily let you guess about). I
want clean solution with no fancy (and somewhat obscure) tex macro doing
magic that only a few are supposed to understand.
When we started with luatex, and thereby mkiv, we immediately went full
unicode math (also with old fonts) and primes (plus a few other things)
were a pain in the butt from the start due to fonts. For more than a
decade I tried to catch this automagically by runtime patching and that
works ok for most fonts but as recently more opentype math fonts showed
up, some actually more opentypish than what we had, the decision was
made to delegate this to the goodies mechanism than Mikael refers to. It
means that we can control individual fonts (and users can patch that
themselves if needed) because in the end, as always with fonts, scripts,
languages and probably most of tex, heuristics tend to fail and clash.
It means that, as Wolfgang explained, you need to specify a goodie file
with \definefontfamily (could be your own copy with personal
preferences). Just for the record, some more is done on goodies and some
more runtime patching might move that goodie control. It actually does
mean that when a font (if ever) gets updated we need to check things
which is why a mismatch in version will be reported on your console.
Among the things we still need to discuss are if we wil freeze fonts in
the distribution (only explicit updates) and if we drop official support
for obsolete or (just) bad (looking) math fonts.
So to summarize: with primes we have to deal with (1) frozen tex math
expectations that won't change (although in context we're free to do
so), which (2) have found their way in unicode, and (3) also in fonts
due to the way traditional tex does it, and (4) with which we cannot
deal with in the engine, so (5) we do it our own contexty way, in the
hope that (6) in the end it all looks good and (7) also gives us some of
the benefits that i don't even dare to bring up here in order not to
make it sound more complex.
As a note: if you notice suboptional things in math fonts, don't
hesitate to make a good minimal example and then ask Mikael to look into
is because he deals with and coordinates the tuning of goodie files.
Hans
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
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://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Math prime issues for some fonts
2021-11-26 18:53 ` Jack Hill via ntg-context
2021-11-26 21:05 ` Mikael Sundqvist via ntg-context
@ 2021-11-27 8:21 ` Wolfgang Schuster via ntg-context
1 sibling, 0 replies; 7+ messages in thread
From: Wolfgang Schuster via ntg-context @ 2021-11-27 8:21 UTC (permalink / raw)
To: Jack Hill; +Cc: Wolfgang Schuster, ntg-context
Jack Hill schrieb am 26.11.2021 um 19:53:
> On Fri, 26 Nov 2021 at 17:39, Wolfgang Schuster
> <wolfgang.schuster.lists@gmail.com> wrote:
>> Jack Hill via ntg-context schrieb am 26.11.2021 um 18:18:
>>> Hi list,
>>>
>>> When I run this test code
>>>
>>> [...]
>>>
>>> on my machine, the prime symbols are being placed too high (except for
>>> latin modern which is normal).
>>> Running the same code on the wiki gives the correct output though.
>>> Does anyone else get the same output? Screenshot attached.
>> Use \definetypeface to load/set the math fonts.
>>
>> \starttext
>>
>> \starttabulate[|l|c|]
>> \FL
>> \BC Font name \BC Math prime \NC\NR
>> \ML
>> \NC Latin Modern Roman \NC \m{x'} \NC\NR
>> \NC TeX Gyre Termes \NC \switchtobodyfont[termes] \m{x'} \NC\NR
>> \NC TeX Gyre Pagella \NC \switchtobodyfont[pagella] \m{x'} \NC\NR
>> \NC TeX Gyre Bonum \NC \switchtobodyfont[bonum] \m{x'} \NC\NR
>> \NC TeX Gyre Schola \NC \switchtobodyfont[schola] \m{x'} \NC\NR
>> \NC STIX Two \NC \switchtobodyfont[stixtwo] \m{x'} \NC\NR
>> \BL
>> \stoptabulate
>>
>> \stoptext
>>
>> Wolfgang
> Thanks, \definetypeface fixes it. Should I not be using \definefontfamily?
> I've just checked eulernova and the prime is still too high for this font.
>
> \switchtobodyfont[eulernova]
> \starttext
> \m{x'}
> \stoptext
To set the math font \definetypeface is the better choice because
ConTeXt loads patches for most math fonts to improve the spacing for
primes etc.
You can use \definefontfamily to set the math font but then you have to
load these patches yourself (\definefontfamily [...] [...] [...]
[extras=...,goodies=...]). For a few fonts these patches are loaded
automatically but the system is not always up to date.
What I suggest is to use \definefontfamily to select your text fonts
(serif, sans and mono) in combination with \definetypeface for the math
font. One reason where \definefontfamily is the better choice for the
math font is when you try to use fallbacks for the math font (e.g. to
have sans serif letters in math mode).
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://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Math prime issues for some fonts
2021-11-26 18:53 ` Jack Hill via ntg-context
@ 2021-11-26 21:05 ` Mikael Sundqvist via ntg-context
2021-11-27 12:28 ` Hans Hagen via ntg-context
2021-11-27 8:21 ` Wolfgang Schuster via ntg-context
1 sibling, 1 reply; 7+ messages in thread
From: Mikael Sundqvist via ntg-context @ 2021-11-26 21:05 UTC (permalink / raw)
To: mailing list for ConTeXt users; +Cc: Mikael Sundqvist
[-- Attachment #1: Type: text/plain, Size: 3509 bytes --]
Hi Jack,
I've been working with Hans on math in general and primes in
particular in the last week. I do not understand all the details, but
I think primes are handled differently now, and that one essentially
need to have some tuning in goodie files (the reason is that they are
done differently in different fonts, and that there was not simple
one-fits-all solution). We have not touched eulernova yet.
In any case, if you replace euler-math.lfg and type-imp-euler.mkiv in
ConTeXt-lmtx/tex/texmf-context/tex/context/fonts/mkiv/ with the
attached files, I think at least the primes should look OK (you could
experiment with the values in euler-math.lfg). The sample file
\setupbodyfont[eulernova]
\starttext
\m{x'(t)f'(x)f''(x)e^{f'(x)}}
\stoptext
looks OK here.
/Mikael
On Fri, Nov 26, 2021 at 7:54 PM Jack Hill via ntg-context
<ntg-context@ntg.nl> wrote:
>
> On Fri, 26 Nov 2021 at 17:39, Wolfgang Schuster
> <wolfgang.schuster.lists@gmail.com> wrote:
> >
> > Jack Hill via ntg-context schrieb am 26.11.2021 um 18:18:
> > > Hi list,
> > >
> > > When I run this test code
> > >
> > > \definefontfamily[trm][math][tex gyre termes math]
> > > \definefontfamily[pag][math][tex gyre pagella math]
> > > \definefontfamily[bon][math][tex gyre bonum math]
> > > \definefontfamily[sch][math][tex gyre schola math]
> > > \definefontfamily[stx][math][stix two math]
> > > \starttext
> > > \starttabulate[|c|c|]
> > > \FL
> > > \NC \bf Font name \NC \bf Math prime \NR
> > > \ML
> > > \NC Latin modern \NC \m{x'} \NR
> > > \NC Termes \NC \switchtobodyfont[trm] \m{x'} \NR
> > > \NC Pagella \NC \switchtobodyfont[pag] \m{x'} \NR
> > > \NC Bonum \NC \switchtobodyfont[bon] \m{x'} \NR
> > > \NC Schola \NC \switchtobodyfont[sch] \m{x'} \NR
> > > \NC Stix \NC \switchtobodyfont[stx] \m{x'} \NR
> > > \BL
> > > \stoptabulate
> > > \stoptext
> > >
> > > on my machine, the prime symbols are being placed too high (except for
> > > latin modern which is normal).
> > > Running the same code on the wiki gives the correct output though.
> > > Does anyone else get the same output? Screenshot attached.
> >
> > Use \definetypeface to load/set the math fonts.
> >
> > \starttext
> >
> > \starttabulate[|l|c|]
> > \FL
> > \BC Font name \BC Math prime \NC\NR
> > \ML
> > \NC Latin Modern Roman \NC \m{x'} \NC\NR
> > \NC TeX Gyre Termes \NC \switchtobodyfont[termes] \m{x'} \NC\NR
> > \NC TeX Gyre Pagella \NC \switchtobodyfont[pagella] \m{x'} \NC\NR
> > \NC TeX Gyre Bonum \NC \switchtobodyfont[bonum] \m{x'} \NC\NR
> > \NC TeX Gyre Schola \NC \switchtobodyfont[schola] \m{x'} \NC\NR
> > \NC STIX Two \NC \switchtobodyfont[stixtwo] \m{x'} \NC\NR
> > \BL
> > \stoptabulate
> >
> > \stoptext
> >
> > Wolfgang
>
> Thanks, \definetypeface fixes it. Should I not be using \definefontfamily?
> I've just checked eulernova and the prime is still too high for this font.
>
> \switchtobodyfont[eulernova]
> \starttext
> \m{x'}
> \stoptext
> ___________________________________________________________________________________
> 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://context.aanhet.net
> archive : https://bitbucket.org/phg/context-mirror/commits/
> wiki : http://contextgarden.net
> ___________________________________________________________________________________
[-- Attachment #2: euler-math.lfg --]
[-- Type: application/octet-stream, Size: 566 bytes --]
-- this file might go away and is for experiments only
return {
name = "euler-math",
version = "1.00",
comment = "Goodies that complement euler math.",
author = "Hans Hagen",
copyright = "ConTeXt development team",
mathematics = {
tweaks = {
aftercopying = {
{
tweak = "fixprimes",
factor = 0.9,
smaller = true,
scale = 0.60,
fake = 0.75,
},
},
},
},
}
[-- Attachment #3: type-imp-euler.mkiv --]
[-- Type: application/octet-stream, Size: 4467 bytes --]
%D \module
%D [ file=type-otf,
%D version=2007.07.30,
%D title=\CONTEXT\ Typescript Macros,
%D subtitle=Euler,
%D author=Hans Hagen,
%D date=\currentdate,
%D copyright={PRAGMA ADE \& \CONTEXT\ Development Team}]
%C
%C This module is part of the \CONTEXT\ macro||package and is
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
%C details.
\loadtypescriptfile[texgyre]
\loadtypescriptfile[dejavu]
% U+0000 upto U+3100 is probably ok, but even then we don't want a mix of accented
\resetfontfallback [euleroverpagella]
\resetfontfallback [pagellaovereuler]
% 0x1D455 : italic h
\definefontfallback [euleroverpagella] [\s!file:euler.otf] [0x02100-0x02BFF] [\s!check=yes,\c!force=yes]
\definefontfallback [euleroverpagella] [\s!file:euler.otf] [0x1D400-0x1D7FF] [\s!check=yes,\c!force=yes]
\definefontfallback [euleroverpagella] [texgyrepagella-math] [0x0210E] [\s!check=yes,\c!force=\v!yes]
%definefontfallback [euleroverpagella] [\s!file:euler.otf] [0x1D538-0x1D550] [\s!check=yes,\c!force=yes]
\definefontfallback [pagellaovereuler] [texgyrepagella-math] [0x02100-0x02BFF] [\s!check=yes]
\definefontfallback [pagellaovereuler] [texgyrepagella-math] [0x1D400-0x1D7FF] [\s!check=yes]
\definefontfallback [pagellaovereuler] [texgyrepagella-math] [0x1D400-0x1D7FF] [\s!check=yes]
\definefontfallback [pagellaovereuler] [texgyrepagella-math] [0x0210E] [\s!check=yes,\c!force=\v!yes]
%definefontfallback [pagellaovereuler] [texgyrepagella-math] [0x1D538-0x1D550] [\s!check=yes]
% example for aditya:
% \definefontfallback [pagellaovereuler] [texgyrepagella-math] [lowercasenormal] [offset=uppercasenormal,force=yes]
% \definefontfallback [pagellaovereuler] [texgyrepagella-math] [uppercasenormal] [offset=lowercasenormal,force=yes]
% \definefontfallback [pagellaovereuler] [texgyrepagella-math] [uppercasebolditalic] [force=yes]
% \definefontfallback [pagellaovereuler] [texgyrepagella-math] [lowercasebolditalic] [force=yes]
\starttypescriptcollection[pagella-eulernova]
\starttypescript [\s!serif] [eulernova] [\s!name]
\setups[\s!font:\s!fallback:\s!serif]
\definefontsynonym [\s!Serif] [\s!file:euler.otf] [\s!features=\s!default]
\stoptypescript
\starttypescript [\s!math] [eulernova] [\s!name]
% \loadfontgoodies[euler-math]
\definefontsynonym [MathRoman] [\s!file:euler.otf] [\s!features={\s!math\mathsizesuffix,mathextra},\s!goodies=euler-math]
\stoptypescript
\starttypescript [pagella-eulernova]
\definetypeface [\typescriptone] [\s!rm] [\s!serif] [pagella] [\s!default]
\definetypeface [\typescriptone] [\s!tt] [\s!mono] [dejavu] [\s!default] [\s!rscale=0.9]
\definetypeface [\typescriptone] [\s!mm] [\s!math] [eulernova] [\s!default]
\quittypescriptscanning
\stoptypescript
\starttypescript [eulernova]
\definetypeface [\typescriptone] [\s!rm] [\s!serif] [eulernova] [\s!default]
\definetypeface [\typescriptone] [\s!tt] [\s!mono] [dejavu] [\s!default] [\s!rscale=0.9]
\definetypeface [\typescriptone] [\s!mm] [\s!math] [eulernova] [\s!default]
\quittypescriptscanning
\stoptypescript
\starttypescript [\s!math] [euleroverpagella] [\s!name]
\definefontsynonym [MathRoman] [texgyrepagella-math] [\s!features={\s!math\mathsizesuffix,mathextra},\s!fallbacks=euleroverpagella]
\stoptypescript
\starttypescript [\s!math] [pagellaovereuler] [\s!name]
\definefontsynonym [MathRoman] [\s!file:euler.otf] [\s!features={\s!math\mathsizesuffix,mathextra},\s!fallbacks=pagellaovereuler]
\stoptypescript
\starttypescript [pagella-with-euler]
\definetypeface [\typescriptone] [\s!rm] [\s!serif] [pagella] [\s!default]
\definetypeface [\typescriptone] [\s!tt] [\s!mono] [dejavu] [\s!default] [\s!rscale=0.9]
\definetypeface [\typescriptone] [\s!mm] [\s!math] [euleroverpagella] [\s!default]
\quittypescriptscanning
\stoptypescript
\starttypescript [euler-with-pagella]
\definetypeface [\typescriptone] [\s!rm] [\s!serif] [eulernova] [\s!default]
\definetypeface [\typescriptone] [\s!tt] [\s!mono] [dejavu] [\s!default] [\s!rscale=0.9]
\definetypeface [\typescriptone] [\s!mm] [\s!math] [pagellaovereuler] [\s!default]
\quittypescriptscanning
\stoptypescript
\stoptypescriptcollection
[-- Attachment #4: Type: text/plain, Size: 493 bytes --]
___________________________________________________________________________________
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://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Math prime issues for some fonts
2021-11-26 17:39 ` Wolfgang Schuster via ntg-context
@ 2021-11-26 18:53 ` Jack Hill via ntg-context
2021-11-26 21:05 ` Mikael Sundqvist via ntg-context
2021-11-27 8:21 ` Wolfgang Schuster via ntg-context
0 siblings, 2 replies; 7+ messages in thread
From: Jack Hill via ntg-context @ 2021-11-26 18:53 UTC (permalink / raw)
To: ntg-context; +Cc: Jack Hill
On Fri, 26 Nov 2021 at 17:39, Wolfgang Schuster
<wolfgang.schuster.lists@gmail.com> wrote:
>
> Jack Hill via ntg-context schrieb am 26.11.2021 um 18:18:
> > Hi list,
> >
> > When I run this test code
> >
> > \definefontfamily[trm][math][tex gyre termes math]
> > \definefontfamily[pag][math][tex gyre pagella math]
> > \definefontfamily[bon][math][tex gyre bonum math]
> > \definefontfamily[sch][math][tex gyre schola math]
> > \definefontfamily[stx][math][stix two math]
> > \starttext
> > \starttabulate[|c|c|]
> > \FL
> > \NC \bf Font name \NC \bf Math prime \NR
> > \ML
> > \NC Latin modern \NC \m{x'} \NR
> > \NC Termes \NC \switchtobodyfont[trm] \m{x'} \NR
> > \NC Pagella \NC \switchtobodyfont[pag] \m{x'} \NR
> > \NC Bonum \NC \switchtobodyfont[bon] \m{x'} \NR
> > \NC Schola \NC \switchtobodyfont[sch] \m{x'} \NR
> > \NC Stix \NC \switchtobodyfont[stx] \m{x'} \NR
> > \BL
> > \stoptabulate
> > \stoptext
> >
> > on my machine, the prime symbols are being placed too high (except for
> > latin modern which is normal).
> > Running the same code on the wiki gives the correct output though.
> > Does anyone else get the same output? Screenshot attached.
>
> Use \definetypeface to load/set the math fonts.
>
> \starttext
>
> \starttabulate[|l|c|]
> \FL
> \BC Font name \BC Math prime \NC\NR
> \ML
> \NC Latin Modern Roman \NC \m{x'} \NC\NR
> \NC TeX Gyre Termes \NC \switchtobodyfont[termes] \m{x'} \NC\NR
> \NC TeX Gyre Pagella \NC \switchtobodyfont[pagella] \m{x'} \NC\NR
> \NC TeX Gyre Bonum \NC \switchtobodyfont[bonum] \m{x'} \NC\NR
> \NC TeX Gyre Schola \NC \switchtobodyfont[schola] \m{x'} \NC\NR
> \NC STIX Two \NC \switchtobodyfont[stixtwo] \m{x'} \NC\NR
> \BL
> \stoptabulate
>
> \stoptext
>
> Wolfgang
Thanks, \definetypeface fixes it. Should I not be using \definefontfamily?
I've just checked eulernova and the prime is still too high for this font.
\switchtobodyfont[eulernova]
\starttext
\m{x'}
\stoptext
___________________________________________________________________________________
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://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Math prime issues for some fonts
2021-11-26 17:18 Jack Hill via ntg-context
@ 2021-11-26 17:39 ` Wolfgang Schuster via ntg-context
2021-11-26 18:53 ` Jack Hill via ntg-context
0 siblings, 1 reply; 7+ messages in thread
From: Wolfgang Schuster via ntg-context @ 2021-11-26 17:39 UTC (permalink / raw)
To: mailing list for ConTeXt users, Jack Hill via ntg-context
Cc: Wolfgang Schuster, Jack Hill
Jack Hill via ntg-context schrieb am 26.11.2021 um 18:18:
> Hi list,
>
> When I run this test code
>
> \definefontfamily[trm][math][tex gyre termes math]
> \definefontfamily[pag][math][tex gyre pagella math]
> \definefontfamily[bon][math][tex gyre bonum math]
> \definefontfamily[sch][math][tex gyre schola math]
> \definefontfamily[stx][math][stix two math]
> \starttext
> \starttabulate[|c|c|]
> \FL
> \NC \bf Font name \NC \bf Math prime \NR
> \ML
> \NC Latin modern \NC \m{x'} \NR
> \NC Termes \NC \switchtobodyfont[trm] \m{x'} \NR
> \NC Pagella \NC \switchtobodyfont[pag] \m{x'} \NR
> \NC Bonum \NC \switchtobodyfont[bon] \m{x'} \NR
> \NC Schola \NC \switchtobodyfont[sch] \m{x'} \NR
> \NC Stix \NC \switchtobodyfont[stx] \m{x'} \NR
> \BL
> \stoptabulate
> \stoptext
>
> on my machine, the prime symbols are being placed too high (except for
> latin modern which is normal).
> Running the same code on the wiki gives the correct output though.
> Does anyone else get the same output? Screenshot attached.
Use \definetypeface to load/set the math fonts.
\starttext
\starttabulate[|l|c|]
\FL
\BC Font name \BC Math prime \NC\NR
\ML
\NC Latin Modern Roman \NC \m{x'} \NC\NR
\NC TeX Gyre Termes \NC \switchtobodyfont[termes] \m{x'} \NC\NR
\NC TeX Gyre Pagella \NC \switchtobodyfont[pagella] \m{x'} \NC\NR
\NC TeX Gyre Bonum \NC \switchtobodyfont[bonum] \m{x'} \NC\NR
\NC TeX Gyre Schola \NC \switchtobodyfont[schola] \m{x'} \NC\NR
\NC STIX Two \NC \switchtobodyfont[stixtwo] \m{x'} \NC\NR
\BL
\stoptabulate
\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://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 7+ messages in thread
* Math prime issues for some fonts
@ 2021-11-26 17:18 Jack Hill via ntg-context
2021-11-26 17:39 ` Wolfgang Schuster via ntg-context
0 siblings, 1 reply; 7+ messages in thread
From: Jack Hill via ntg-context @ 2021-11-26 17:18 UTC (permalink / raw)
To: ntg-context; +Cc: Jack Hill
[-- Attachment #1.1: Type: text/plain, Size: 905 bytes --]
Hi list,
When I run this test code
\definefontfamily[trm][math][tex gyre termes math]
\definefontfamily[pag][math][tex gyre pagella math]
\definefontfamily[bon][math][tex gyre bonum math]
\definefontfamily[sch][math][tex gyre schola math]
\definefontfamily[stx][math][stix two math]
\starttext
\starttabulate[|c|c|]
\FL
\NC \bf Font name \NC \bf Math prime \NR
\ML
\NC Latin modern \NC \m{x'} \NR
\NC Termes \NC \switchtobodyfont[trm] \m{x'} \NR
\NC Pagella \NC \switchtobodyfont[pag] \m{x'} \NR
\NC Bonum \NC \switchtobodyfont[bon] \m{x'} \NR
\NC Schola \NC \switchtobodyfont[sch] \m{x'} \NR
\NC Stix \NC \switchtobodyfont[stx] \m{x'} \NR
\BL
\stoptabulate
\stoptext
on my machine, the prime symbols are being placed too high (except for
latin modern which is normal).
Running the same code on the wiki gives the correct output though.
Does anyone else get the same output? Screenshot attached.
Jack
[-- Attachment #1.2: Type: text/html, Size: 1148 bytes --]
[-- Attachment #2: pdf-output.png --]
[-- Type: image/png, Size: 14682 bytes --]
[-- Attachment #3: Type: text/plain, Size: 493 bytes --]
___________________________________________________________________________________
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://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2021-11-29 17:40 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-29 17:40 Math prime issues for some fonts Jack Hill via ntg-context
-- strict thread matches above, loose matches on Subject: below --
2021-11-26 17:18 Jack Hill via ntg-context
2021-11-26 17:39 ` Wolfgang Schuster via ntg-context
2021-11-26 18:53 ` Jack Hill via ntg-context
2021-11-26 21:05 ` Mikael Sundqvist via ntg-context
2021-11-27 12:28 ` Hans Hagen via ntg-context
2021-11-27 8:21 ` Wolfgang Schuster via ntg-context
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).