1

I try to use a font (VAG-HurryPen), downloaded from here. However, when I compile my document using XeLaTeX engine, I get an error

! Package polyglossia Error: The current roman font does not contain the Greek script! (polyglossia) Please define \greekfont with \newfontfamily.

Here is the "language set up"

\usepackage{fontspec,xgreek}
\defaultfontfeatures{Mapping=tex-text}

\setmainfont[Mapping=tex-text]{VAG-HurryPen}
\usepackage{polyglossia}
\setdefaultlanguage[variant=modern]{greek}

I tried to solve my problem following this solution:

\defaultfontfeatures{Mapping=tex-text}

\setmainfont[Mapping=tex-text]{VAG-HurryPen}
\newfontfamily\greekfontsf[Script=Greek]{VAG-HurryPen}
\usepackage{polyglossia}
\setdefaultlanguage[variant=modern]{greek}

, but the problem still remains

Yorgos
  • 2,694

1 Answers1

3

I think it should be \greekfont not \greekfontsf. Also you can't specify Script=Greek because VAG-HurryPen does not have this OpenType script (even though it has the glyphs).

\documentclass{article}
\usepackage{fontspec}
\usepackage{polyglossia}
\setmainfont[Mapping=tex-text]{VAG-HurryPen}
\newfontfamily\greekfont[Mapping=tex-text]{VAG-HurryPen}
\setdefaultlanguage[variant=modern]{greek}
\begin{document}
αβγδε
\end{document}
David Purton
  • 25,884
  • The Mapping=tex-text option should be Ligatures=TeX, but it's not needed because it's issued by default with fontspec. – egreg Aug 21 '16 at 11:08