[lucida] need to manually specify bold/italic fonts with current fontspec

Bruno Voisin bvoisin at icloud.com
Tue Jan 22 10:06:23 CET 2019


> On 22 Jan 2019, at 00:53, Karl Berry <karl at freefriends.org> wrote:
> 
> I can't imagine why being on a mac per se should make a difference.
> For me, both xelatex and luatex are finding the .fontspec.

It seems a lettercase matter, so maybe that's where the mac makes a difference.

As is, I'm getting the same as Calum mostly:

(./lucidabrightot.fontspec) (./lucidabrightot.fontspec)
(./lucidabrightot.fontspec) (./articlekb.aux)

LaTeX Font Warning: Font shape `TU/lucidabrightot(0)/bx/n' undefined
(Font)              using `TU/lucidabrightot(0)/m/n' instead on input line 5.

Odd!

After some experimentation (on a MacBook with macOS Mojave and MacTeX 2018), it seems:

- The name of the .fontspec file and the optional argument of \defaultfontfeatures must use the same lettercase. So if it's

	\defaultfontfeatures[LucidaBrightOT]

then the file name should be

	LucidaBrightOT.fontspec

- The fontspec call must also use the same lettercase, ie

	\setmainfont{LucidaBrightOT}

Also, note that

	\setmainfont{Lucida Bright OT}

works in LuaLaTeX but not XeLaTeX (in the very quick tests I did).

How confusing!

With the above changes, I'm getting

(./LucidaBrightOT.fontspec) (./LucidaBrightOT.fontspec)
(./LucidaBrightOT.fontspec) (./articlekb.aux) [1{/usr/local/texlive/2018/texmf-
var/fonts/map/pdftex/updmap/pdftex.map}] (./articlekb.aux))
 414 words of node memory still in use:
   3 hlist, 1 vlist, 1 rule, 2 glue, 3 kern, 1 glyph, 5 attribute, 49 glue_spec
, 5 attribute_list, 1 write nodes
   avail lists: 2:27,3:3,4:2,5:25,6:1,7:45,8:1,9:6,11:2
</usr/local/texlive/2018/texmf-dist/fonts/opentype/public/lm/lmmono12-regular.o
tf></usr/local/texlive/texmf-local/fonts/opentype/bh/lucidaot/LucidaBrightOT-It
alic.otf></usr/local/texlive/texmf-local/fonts/opentype/bh/lucidaot/LucidaBrigh
tOT-Demi.otf></usr/local/texlive/texmf-local/fonts/opentype/bh/lucidaot/LucidaB
rightOT.otf>
Output written on articlekb.pdf (1 page, 8150 bytes).

On p. 12 of the doc of fontspec v2.6k, dated 2019/01/16, Will writes

"N.B. that while spaces are stripped, the lettercase of the names should match."

So the lettercase should be normal I guess, but the space issue looks like a bug.

During testing, for good measure I also replaced ExternalLocation (deprecated) by Path in the .fontspec file, but it didn't seem to matter.

Bruno

PS I may be slow on the answering, I'm busy with FileVault -- encryption -- issues on my main -- and only -- setup.




More information about the lucida mailing list