![デフォルトのフォントでXeLaTeXでギリシャ語を書く](https://rvso.com/image/305777/%E3%83%87%E3%83%95%E3%82%A9%E3%83%AB%E3%83%88%E3%81%AE%E3%83%95%E3%82%A9%E3%83%B3%E3%83%88%E3%81%A7XeLaTeX%E3%81%A7%E3%82%AE%E3%83%AA%E3%82%B7%E3%83%A3%E8%AA%9E%E3%82%92%E6%9B%B8%E3%81%8F.png)
私はやってみたいですこれcrm10 フォントで。どうすればいいですか? いくつかのフォントを試してみましたが、気に入りません。
\documentclass{scrreprt}
\usepackage{fontspec}
\setmainfont{Times New Roman}
\setsansfont{Arial}
\newfontfamily\greekfont[Script=Greek]{Linux Libertine O}
\newfontfamily\greekfontsf[Script=Greek]{Linux Libertine O}
\usepackage{polyglossia}
\setdefaultlanguage{greek}
\begin{document}
\tableofcontents{}
\section{Αυτό είναι ελληνικά.}
{\bfseries Welcome to Greek:} Αυτό είναι ελληνικά
Or Russian: Привет
Or Hebrew: מה הבעיה?
\end{document}
答え1
CMU フォントは Computer Modern (およびギリシャ語用の CB フォント) に基づいています。
\documentclass{scrreprt}
\usepackage{fontspec}
\setmainfont{CMU Serif}
\setsansfont{CMU Sans Serif}
\newfontfamily{\greekfont}{CMU Serif}
\newfontfamily{\greekfontsf}{CMU Sans Serif}
\usepackage{polyglossia}
\setdefaultlanguage{greek}
\begin{document}
\tableofcontents{}
\section{Αυτό είναι ελληνικά.}
{\bfseries Welcome to Greek:} Αυτό είναι ελληνικά
Or Russian: Привет
%Or Hebrew: מה הבעיה?
\end{document}
ただし、ヘブライ語はサポートされていません。
異なるフォントと以下の使用法でヘブライ語をサポートできますucharclasses
:
\documentclass{scrreprt}
\usepackage{fontspec}
\setmainfont{CMU Serif}
\setsansfont{CMU Sans Serif}
\newfontfamily{\greekfont}{CMU Serif}
\newfontfamily{\greekfontsf}{CMU Sans Serif}
\newfontfamily{\hebrewfont}{Linux Libertine O}[Scale=MatchUppercase]
\usepackage{polyglossia}
\setdefaultlanguage{greek}
\usepackage[Latin,Greek,Hebrew,Cyrillic]{ucharclasses}
\setTransitionsFor{Hebrew}{\begingroup\hebrewfont}{\endgroup}
\begin{document}
\tableofcontents{}
\section{Αυτό είναι ελληνικά.}
{\bfseries Welcome to Greek:} Αυτό είναι ελληνικά
Or Russian: Привет
Or Hebrew: מה הבעיה?
\end{document}