[tex-live] Font features linked with fontspec-preparse-external apparently broken in fontspec

Bruno Voisin bruno.voisin at legi.cnrs.fr
Wed Oct 15 11:49:01 CEST 2014


> Le 15 oct. 2014 à 06:40, Akira Kakuto <kakuto at fuk.kindai.ac.jp> a écrit :
> 
> It looks like I wrote on an unrelated issue, sorry.

Not at all: you actually gave the key towards the solution of the problem.

After more trial-and-error, it turns out everything works provided the font names are included in brackets, like in your example, with or without the .otf extension, and either in full or as shorthands like *-Demi. So both

\defaultfontfeatures[LucidaBrightOT]
  {
   UprightFont = [LucidaBrightOT.otf],
   BoldFont = [LucidaBrightOT-Demi.otf],
   ItalicFont = [LucidaBrightOT-Italic.otf],
   BoldItalicFont = [LucidaBrightOT-DemiItalic.otf]
  }

and

\defaultfontfeatures[LucidaBrightOT]
  {
   UprightFont = [LucidaBrightOT],
   BoldFont = [LucidaBrightOT-Demi],
   ItalicFont = [LucidaBrightOT-Italic],
   BoldItalicFont = [LucidaBrightOT-DemiItalic]
  }

in a file LucidaBrightOT.fontspec work, allowing the user to just write either of

\setmainfont{Lucida Bright OT}
\setmainfont{LucidaBrightOT}

in her/his LaTeX file. The abbreviated version

\defaultfontfeatures[LucidaBrightOT]
  {
   UprightFont = [LucidaBrightOT],
   BoldFont = [*-Demi],
   ItalicFont = [*-Italic],
   BoldItalicFont = [*-DemiItalic]
  }

also works, but only with

\setmainfont{LucidaBrightOT}

This makes sense according to luaotfload.pdf and xetex-reference.pdf, but it's not in the fontspec doc, and as far as I remember it wasn't necessary before v2.4.

Thanks again for your help,

Bruno





More information about the tex-live mailing list