fontspec icon indicating copy to clipboard operation
fontspec copied to clipboard

Linux xelatex and type1 font

Open syvshc opened this issue 2 years ago • 2 comments

Description

I'm an Arch Linux user, when I want to use \setmainfont{Libertinus Serif} to set main font. I straightly met an xdvipdfmx's error:

xdvipdfmx:fatal: Invalid font: -1 (0)

This will not happen on my Windows pc.

I also post it at tex.se: https://tex.stackexchange.com/questions/612718/using-other-fonts-caused-xdvipdfmxfatal-invalid-font-1

And I refered to https://github.com/wspr/fontspec/issues/419 but I didn't find useful information.

Check/indicate

  • [x] Relevant for XeTeX
  • [ ] Relevant for LuaTeX
  • [x] Issue tracker has been searched for similar issues?
  • [x] Links to <tex.stackexchange.com> discussion if appropriate

Minimal example demonstrating the issue

\documentclass{article}
\usepackage{fontspec}
\setmainfont{Libertinus Serif}
\begin{document}
    Here are some lines to read. 
\end{document}

Further details

syvshc avatar Sep 01 '21 13:09 syvshc

I read https://github.com/wspr/fontspec/issues/419 again.

fontspec does not have anything to do with font lookup, it just uses whatever the engine provides.

It means that the xetex engine choose the type1 version font, not fontspec. So maybe I should ask xdvipdfmx that "Why xdvipdfmx can't deal with 'type1' font on linux?"

syvshc avatar Sep 01 '21 13:09 syvshc

I would guess that you configured fontconfig to look for type1 fonts, see

https://tug.org/pipermail/tex-live/2021-April/046700.html

On Wed, 1 Sept 2021 at 14:24, syvshc @.***> wrote:

I read #419 https://github.com/wspr/fontspec/issues/419 again.

fontspec does not have anything to do with font lookup, it just uses whatever the engine provides.

It means that the xetex engine choose the type1 version font, not fontspec. So maybe I should ask xdvipdfmx that "Why xdvipdfmx can't deal with 'type1' font on linux?"

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/wspr/fontspec/issues/448#issuecomment-910283080, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAJVYATEAVZ2P3TYIGYM2HLT7YSRPANCNFSM5DGOXVCQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

davidcarlisle avatar Sep 01 '21 13:09 davidcarlisle