[NTG-context] tlig feature sometimes does not work

Hans Hagen j.hagen at xs4all.nl
Fri Mar 12 18:32:13 CET 2021

On 3/11/2021 2:05 AM, Mohammad Hossein Bateni wrote:
> Hi,
> Since most fonts do not have the standard tex ligatures built in, I tend 
> to add them when I load the fonts.  Once in a while, I run into fonts 
> where this does not work.
> See the attached tex/pdf files.  I basically load the font as follows:
> \definefontfeature[tf][arabic][tlig=yes]
> \definedfont[dejavusansmono*tf]
> This works fine for DejaVuSansMono and for one Farsi font I use 
> (https://github.com/rastikerdar/vazir-font/blob/master/dist/Vazir-Regular.ttf 
> <https://github.com/rastikerdar/vazir-font/blob/master/dist/Vazir-Regular.ttf>) 
> but not for this other Farsi font 
> (https://github.com/aminabedi68/Mikhak/blob/master/Font/ttf/Mikhak-Medium.ttf 
> <https://github.com/aminabedi68/Mikhak/blob/master/Font/ttf/Mikhak-Medium.ttf>).  
> Perhaps this is because the last font is not standard, but 
> TrueType/OpenType standard is sometimes up for interpretation.
> I see two strange symptoms here:
> \showotfcomposition displays the tlig feature differently for the last 
> font.  It appears in the "extra" list, not in "basic".  Why is that?  
> What does this mean anyway?

The font doesn't have endash and emdash so there is nothing to construct 
from the double -

     \definedfont[file:Mikhak-Medium.ttf*default] foo--bar

Just ask the author to add these characters and you're fine.


                                           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