I use lualatex and utf8 source. I want to use the Latin Modern fonts (including math). If I include e.g. the character ε in my source file; it does not appear in the output. I've tried changing the font to TeX Gyre Pagella (with fontspec) and the ε appears as I want. I assume the Latin Modern font I'm using does not support greek characters.
Now; obviously someone has created greek glyphs for Latin Modern Math, so I'm surprised the text mode greek letters are incomplete in Latin Modern. Is there anything wrong with doing e.g.
\setmainfont{latinmodern-math.otf}
or some other hacky workaround? Is there just no way of typesetting greek characters in text mode with Latin Modern? I don't want to have to surround every greek letter with $$
(I appreciate the irony of trying to write greek letters with a font that has latin in the name, but I'm surprised the solution isn't more obvious)
MWE:
\documentclass{minimal}
\usepackage{fontspec}
\setmainfont{Latin Modern Roman}
\usepackage{unicode-math}
\setmathfont{latinmodern-math.otf}
\begin{document}
This text appears fine.
The following does not, only the capital omega appears: ∆πΩε.
This math does appear as expected, however: $∆πΩε$.
\end{document}
Best Answer
The Latin Modern fonts don't have the full set of Greek letters, but only some of them.
If you need only some Greek words, you can benefit from the
ucharclasses
package, as shown in the example. If you need longer passages in Greek, it's convenient to load Polyglossia.After you've chosen the font that suits you (maybe experimenting with other Greek fonts), give it directly the name of
\greekfont
.