Skip to content

Font not found when Extension is used #550

@caizixian

Description

@caizixian
\defaultfontfeatures[Source Code Pro]{
    UprightFont = SourceCodePro-Regular,
    BoldFont = SourceCodePro-Semibold,
    ItalicFont = SourceCodePro-It,
    BoldItalicFont = SourceCodePro-SemiboldIt
}

works, but

\defaultfontfeatures[Source Code Pro]{
    Extension = .otf,
    UprightFont = SourceCodePro-Regular,
    BoldFont = SourceCodePro-Semibold,
    ItalicFont = SourceCodePro-It,
    BoldItalicFont = SourceCodePro-SemiboldIt
}

complains about SourceCodePro-It not found. Interestingly, only SourceCodePro-It is affected. If you use, e.g., SourceCodePro-LightIt, then the font can also be found.

The Source Code Pro is downloaded from the latest official release https://github.com/adobe-fonts/source-code-pro/releases/tag/2.042R-u%2F1.062R-i%2F1.026R-vf and installed into ~/Library/Fonts

XeLaTeX version

XeTeX 3.141592653-2.6-0.999996 (TeX Live 2024)
kpathsea version 6.4.0
Copyright 2024 SIL International, Jonathan Kew and Khaled Hosny.
There is NO warranty.  Redistribution of this software is
covered by the terms of both the XeTeX copyright and
the Lesser GNU General Public License.
For more information about these matters, see the file
named COPYING and the XeTeX source.
Primary author of XeTeX: Jonathan Kew.
Compiled with ICU version 74.2; using 74.2
Compiled with zlib version 1.3.1; using 1.3.1
Compiled with FreeType2 version 2.13.2; using 2.13.2
Compiled with Graphite2 version 1.3.14; using 1.3.14
Compiled with HarfBuzz version 8.3.0; using 8.3.0
Compiled with libpng version 1.6.43; using 1.6.43
Compiled with pplib version v2.2
Using Mac OS X Core Text and Cocoa frameworks

fontspec version fontspec 2024/02/13 v2.9a

Both XeLaTeX and fontspec are from MacTeX 2024.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions