[NTG-context] Font fallback scaling

Hans Hagen j.hagen at xs4all.nl
Thu Apr 12 18:57:53 CEST 2018


On 4/12/2018 6:17 PM, Magnus J wrote:
> I use Adobe Garamond Pro in combination with Termes Math for math (the 
> latter for missing glyphs, Garamond is not very complete). How can I 
> scale size of Termes Math without decreasing the size of the Garamond 
> glyphs in math mode?
> 
> /MJO
> 
> 
>      % define the characters to use for Garamond in math mode
>      \definefontfamilypreset
>          [math:somesymbols]
>          
> [range={0x0002A-0x0002E,0x000A7,0x000B6,0x000D7,0x000F7,0x02020-0x02021,0x02212,0x02219-0x02226,0x02228-0x02265,0x02012,0x0003C-0x0003E,0x0007C},
>           tf=style:regular,
>           offset=lowercasenormal,
>          ]
> 
>      \definefallbackfamily[mainface][mm][Adobe Garamond 
> Pro][math:digitsnormal]
>      \definefallbackfamily[mainface][mm][Adobe Garamond 
> Pro][math:lowercasenormal]
>      \definefallbackfamily[mainface][mm][Adobe Garamond 
> Pro][math:lowercaseitalic]
>      \definefallbackfamily[mainface][mm][Adobe Garamond 
> Pro][math:uppercasenormal]
>      \definefallbackfamily[mainface][mm][Adobe Garamond 
> Pro][math:uppercaseitalic]
>      \definefallbackfamily[mainface][mm][Adobe Garamond 
> Pro][math:somesymbols]
> 
>      \definefontfamily[mainface][rm][Adobe Garamond Pro]
>      \definefontfamily[mainface][mm][TeX Gyre Termes Math][scale=0.9]  % 
> <-- scaling here...
> 
>      \setupbodyfont[mainface,11pt]
> 
>      \starttext
>      100
> 
>      $100$ % <-- leads to math mode that is smaller than text, even for 
> Garamond glyphs
>      \stoptext
     \definefallbackfamily[mainface][math][Adobe Garamond 
Pro][rscale=1.05,range=digitsnormal]
     \definefallbackfamily[mainface][math][Adobe Garamond 
Pro][rscale=1.05,range=lowercasenormal]
     \definefallbackfamily[mainface][math][Adobe Garamond 
Pro][rscale=1.05,range=lowercaseitalic]
     \definefallbackfamily[mainface][math][Adobe Garamond 
Pro][rscale=1.05,range=uppercasenormal]
     \definefallbackfamily[mainface][math][Adobe Garamond 
Pro][rscale=1.05,range=uppercaseitalic]
     \definefallbackfamily[mainface][math][Adobe Garamond 
Pro][rscale=1.05,range=math:somesymbols]

     \definefontfamily     [mainface] [serif] [Adobe Garamond Pro]
     \definefontfamily     [mainface] [math]  [TeX Gyre Termes Math]

     \setupbodyfont[mainface]


-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
        tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------


More information about the ntg-context mailing list