Re: [NTG-context] numerator is too high in \frac{3}{4}, in palatino

2014-05-17 Thread Sanjoy Mahajan
Hans Hagen pra...@wxs.nl writes:

 these are font properties and using a consistent opentype math versus
 a bunch of loosely related type one fonts makes a difference

But shouldn't TeXGyrePagellaMath qualify?

 I've added:

 \starttext

  $\displaystyle 1+{2g\over3}+{2\over3}$ \blank

  \setupmathfractions[topdistance=0pt]

  $\displaystyle 1+{2g\over3}+{2\over3}$ \blank

  \setupmathfractions[bottomdistance=0pt]

  $\displaystyle 1+{2g\over3}+{2\over3}$ \blank

  \setupmathfractions[topdistance=0pt,bottomdistance=0pt]

  $\displaystyle 1+{2g\over3}+{2\over3}$ \blank

 \stoptext

Thanks, Hans.  That is very useful.  

I also recompiled my textbook draft using the latest beta (2014.05.17),
and it works very well.  I tried the topdistance and bottomdistance and
they are mostly working.  To my eye, with topdistance=6pt, the {1\over2}
looks very good again.

However, the settings don't seem to affect fractions inside square
roots.  Here's an example (the 20pt setting is to exaggerate the
possible effect), using 2014.05.17 beta.

\starttext
\placeformula\startformula
\dfrac{ag}{bcd}\quad{ag\over bcd}
\stopformula
\placeformula\startformula
\sqrt{1\over \dfrac{a}{bcd}}
\quad
\sqrt{\dfrac{1}{\dfrac{a}{bcd}}}
\stopformula

\setupmathfractions [topdistance=20pt]

\placeformula\startformula
\dfrac{ag}{bcd}\quad{ag\over bcd}
\stopformula
\placeformula\startformula
\sqrt{1\over \dfrac{a}{bcd}}
\quad
\sqrt{\dfrac{1}{\dfrac{a}{bcd}}}
\stopformula

\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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] numerator is too high in \frac{3}{4}, in palatino

2014-05-06 Thread Hans Hagen

On 5/2/2014 4:46 AM, Sanjoy Mahajan wrote:

I've noticed the following issue with how high the numerator is placed,
but only when using Palatino:

\setupbodyfont[palatino]
\starttext
\startformula
{3\over4}\quad {1\over2}
\stopformula
\stoptext

The 3 and the 1 sit quite high above the division line, esp. in
comparison with the gap below the line (above the 4 and the 2).

The place okay without the \setupbodyfont[palatino], so maybe it is
something incorrect in the font parameters?

The fonts are (from 'pdffonts'):

EUEJAR+TeXGyrePagella-RegularCID Type 0C   Identity-H   yes yes 
yes 18  0
UPBTGS+TeXGyrePagellaMath-RegularCID Type 0C   Identity-H   yes yes 
yes 19  0

And it is compiled with 2014.03.27 20:04 MKIV.


these are font properties and using a consistent opentype math versus a 
bunch of loosely related type one fonts makes a difference


keep in mind that a too small distance can give inconsistent output


Is there a way to adjust the spacing, or an alternative workaround?


I've added:

\starttext

$\displaystyle 1+{2g\over3}+{2\over3}$ \blank

\setupmathfractions[topdistance=0pt]

$\displaystyle 1+{2g\over3}+{2\over3}$ \blank

\setupmathfractions[bottomdistance=0pt]

$\displaystyle 1+{2g\over3}+{2\over3}$ \blank

\setupmathfractions[topdistance=0pt,bottomdistance=0pt]

$\displaystyle 1+{2g\over3}+{2\over3}$ \blank

\stoptext




-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
 | 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] numerator is too high in \frac{3}{4}, in palatino

2014-05-05 Thread Sanjoy Mahajan
I just compared MkII and MkIV in this respect, and the MkII fraction
looks more symmetric (more correct) than the MkIV version.

Here is the MkII code:

\usetypescript[palatino][ec]
\setupbodyfont[palatino]
\starttext
\startformula
{3\over4}\quad {1\over2}
\stopformula
\stoptext

I've attached  (cropped) images to show the difference.

Another difference is in the fonts.  For the MkII version, pdffonts gives

  IVJLXF+TeXGyrePagella-RegularType 1Custom   yes 
yes no   4  0
  IVJLXF+TeXGyrePagella-RegularType 1Custom   yes 
yes no   5  0


For the MkIV version, pdffonts shows a math font (maybe for the
thicker fractional bar):

  EUEJAR+TeXGyrePagella-RegularCID Type 0C   Identity-H   yes 
yes yes 18  0
  UPBTGS+TeXGyrePagellaMath-RegularCID Type 0C   Identity-H   yes 
yes yes 19  0


If you have suggestions for how to change, slightly, the numerator and
denominator placement when using alatino, let me know.

Maybe the entire problem is that the division line is thicker in
Palatino math than in the text font, and maybe sits below the math axis
(so it gets too close to the denominator)?

-Sanjoy

___
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
___

[NTG-context] numerator is too high in \frac{3}{4}, in palatino

2014-05-01 Thread Sanjoy Mahajan
I've noticed the following issue with how high the numerator is placed,
but only when using Palatino:

\setupbodyfont[palatino]
\starttext
\startformula
{3\over4}\quad {1\over2}
\stopformula
\stoptext

The 3 and the 1 sit quite high above the division line, esp. in
comparison with the gap below the line (above the 4 and the 2).

The place okay without the \setupbodyfont[palatino], so maybe it is
something incorrect in the font parameters?

The fonts are (from 'pdffonts'):

EUEJAR+TeXGyrePagella-RegularCID Type 0C   Identity-H   yes yes 
yes 18  0
UPBTGS+TeXGyrePagellaMath-RegularCID Type 0C   Identity-H   yes yes 
yes 19  0

And it is compiled with 2014.03.27 20:04 MKIV.

Is there a way to adjust the spacing, or an alternative workaround?

-Sanjoy
___
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
___