0

I have a document in Japanese (with the luatexja package), but I need to render a sentence in Greek halfway down (actually a lot of languages, but Greek is currently the only one giving issues).

This mwe:

\documentclass{article}
\usepackage{luatexja}
\begin{document}
Japanese: 日本語のサンプルテキスト 

Greek: Παράδειγμα κειμένου στα ελληνικά
\end{document}

Renders like this: enter image description here

As you can see the spacing is off and some characters don't render at all.

I've tried to surround the greek text like so: {\fontfamily{FreeSans}\selectfont Παράδειγμα κειμένου στα ελληνικά} but that didn't work.

1 Answer 1

1

You can change the font used for greek by setting a parameter (found in the documentation) and using \setmainfont to select a suitable font:

\documentclass{article}

\usepackage{luatexja-fontspec}
\ltjsetparameter{jacharrange={-2,-3}}
\setmainfont{FreeSans} 
\begin{document}
Japanese: 日本語のサンプルテキスト 

Greek: Παράδειγμα κειμένου στα ελληνικά


\end{document}

enter image description here

3
  • Thanks Ulrike. This works with full luatexja as well. Where did you find that \ltjsetparameter{jacharrange={-2,-3}} in the docs? Dec 8, 2022 at 13:50
  • Sorry, you are right, I edited my comment at the same time you added your reply Dec 8, 2022 at 13:55
  • 1
    on page 5: Greek and Cyrillic letters, and ISO 8859-1 symbols Dec 8, 2022 at 13:56

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .