Font naming problem
Scott Kostyshak
skostysh at lyx.org
Sun Mar 6 04:51:04 UTC 2022
On Wed, Feb 02, 2022 at 06:39:24PM +0100, Kornel Benko wrote:
> Am Mon, 31 Jan 2022 15:04:24 -0500
> schrieb Scott Kostyshak <skostysh at lyx.org>:
>
> > On Sun, Jan 30, 2022 at 12:51:26PM +0100, Kornel Benko wrote:
> > > This is for lyx2.4 _and_ lyx2.3
> > >
> > > 1. open new file in lyx
> > > 2. write some text
> > > 3. Document->Settings->Fonts
> > > 3a. check: Use non-TeX fonts
> > > 3b. Select roman font: "David CLM"
> > > 3c. Formats->Default output format: PDF(LuaTeX)
> > > 4. Try a preview ==> Package fontspec Error: The font "DavidCLM" cannot be found.
> > > 5. save the file
> > >
> > > 6. Now check that there _is_ a font matching "David"
> > > $ fc-list -f "%{fullname}\n" |grep David
> > > David CLM Medium
> > > David CLM Medium Italic
> > > David CLM Bold Italic
> > > David CLM Bold
> > > 7. OK, now edit the saved file with an editor and change
> > > \font_roman "default" "David CLM [bitstream]"
> > > to
> > > \font_roman "default" "David CLM Medium [bitstream]"
> > > 8. open again with lyx
> > > 9. check the preview now works
> > > 10. Look into Document->Settings->Fonts->Roman
> > > ==> David CLM Medium [bitstream] (not installed)
> > >
> >
> > I can reproduce, although I do not have "[bitstream]" and I'm not sure what refers to
> > above.
> >
> > > This does not feel OK.
> >
> > Agreed. I do not know if it is a LyX issue or a luaotfload issue. It is
> > strange that XeTeX seems to work fine for the same example.
> >
> > I don't understand much, but perhaps the following is related?
> >
> > https://github.com/latex3/luaotfload/issues/78
> >
> > $ luaotfload-tool --find 'David CLM'
> > luaotfload | db : Reload initiated (formats: otf,ttf,ttc); reason: Font "David CLM" not
> > found. luaotfload | resolve : sequence of 3 lookups yielded nothing appropriate.
> > luaotfload | resolve : Cannot find "David CLM" in index.
> > luaotfload | resolve : Hint: use the --fuzzy option to display suggestions.
> > $ luaotfload-tool --find 'David CLM Medium'
> > luaotfload | resolve : Font "David CLM Medium" found!
> > luaotfload | resolve : Resolved file name
> > "/usr/share/fonts/truetype/culmus/DavidCLM-Medium.otf" $
> >
> > Interestingly --fuzzy does not find what I thought it would.
> >
> > $ luaotfload-tool --fuzzy --find 'David CLM'
> > luaotfload | db : Reload initiated (formats: otf,ttf,ttc); reason: Font "David CLM" not
> > found. luaotfload | resolve : sequence of 3 lookups yielded nothing appropriate.
> > luaotfload | resolve : Cannot find "David CLM" in index.
> > luaotfload | resolve : Looking for close matches, this may take a while ...
> > luaotfload | query : Distance from "davidclm": 4
> > David CLM Bold
> > Navilu
>
> Same here BTW.
>
> >
> > Scott
>
> I would blame luaotfload-tool, alas, there is a third player involved here: QT.
> Lyx is getting the list of families from QT at
> src/frontends/qt/GuiDocument.cpp:2686
> so we have no chance to select anything else.
> It would be handy here to enter/modify custom font name IMO.
I think this issue might be fixed on latest TL (either latest TL 21 or TL 22 pretest).
I just did tlmgr update and I can no longer reproduce the original issue.
Scott
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists.lyx.org/pipermail/lyx-devel/attachments/20220305/fe634625/attachment.asc>
More information about the lyx-devel
mailing list