# [NTG-context] Bug in CONTEXT/LuaTeX or just buggy font

Hans Hagen pragma at wxs.nl
Wed Aug 10 17:03:54 CEST 2016

```On 8/9/2016 10:41 PM, Mohammad Hossein Bateni wrote:
> Hello,
>
> I have a bunch of simple fonts for Arabic/Persian.  These fonts lack
> Latin characters, etc., so I use fallbacks to work with them.
>
> I just noticed that \high does not work with them, and have not been
> able to pinpoint the issue.  See the MWE below.
>
>
> \starttypescript [serif][samim][name]
>   \definefontsynonym[Serif][Samim]
> \stoptypescript
>
> \definetypeface [myfont][rm] [serif][samim][default]
> \setupbodyfont [myfont]
>
> \starttext
> %\definedfont[Samim*arabic]
> ۱۲۳\high{۴}۵۶.
> \stoptext
>
>
> I am using Persian digits because the font lacks Latin digits as I
> mentioned.  If I use the \definedfont approach, I don't see the
> character ۴ (argument of \high) at all.  With the typescript approach,
> the same character /is/ typeset but is /not/ raised; it appears on the
> baseline but with smaller size.
>
> Any ideas why this is happening?  Could it be that some parameters, for
> instance, \exheight are not properly set/read for this font?  Actually,
> I looked at the non-math fontdimens in syst-fnt.mkiv, and everything
> except \slantperpoint (expected) and \exheight (awkward) is non-zero.  I
> don't know where \exheight comes from—perhaps from the height of glyph
> for 'x', which the font lacks—however, \emheight is 12pt, although the
> font also lacks a glyph for 'm'.
>
> I am also attaching the font in case that helps.

Normally one sets up a proper bodyfont (and environment if needed) while
you use just a simple font switch and that one is unrelated to any other
font setting.

I'll add two new commands: \sx and \sxx so that you can say:

\setuplow [style=\sx]
\setuphigh[style=\sx]

for such cases. However, as these are derived relative scales they are
normally not compatible with \tx and txx sizes.

Hans

-----------------------------------------------------------------