Cambié a usar poliglosia para algunos textos hebreos y todos los guiones en mi texto volvieron a ser tres guiones.

Cambié a usar poliglosia para algunos textos hebreos y todos los guiones en mi texto volvieron a ser tres guiones.

El cambio de babel a plyglossia en mi texto parece estar asociado con guiones largos (escritos como tres guiones seguidos) que ahora se imprimen como tres guiones.

Supongo que el cambio a poliglosia es accidental. ¿Qué podría estar causando esto?

\documentclass[12pt]{article}

\usepackage{polyglossia}

\setmainlanguage{english}
\setotherlanguage{hebrew}

\newfontfamily{\englishfont}{EB Garamond}

\newfontfamily{\hebrewfont}[Script=Hebrew]{Hadasim CLM}
\newfontfamily{\hebrewfontsf}[Script=Hebrew]{Miriam CLM}
\newfontfamily{\hebrewfonttt}[Script=Hebrew]{Miriam Mono CLM}


\title{Using Hebrew Fonts on Overleaf with polyglossia \\\texthebrew{דוגמא לגופני ברירת מחדל}}
\author{Foo}

\begin{document}

\maketitle

I don't know why it is doing this --- but  I don't like it.

\end{document}

Respuesta1

\newfontfamilyno carga el \defaultfontfeatures.

Nota: cambié la fuente hebrea por una que tengo.

\documentclass[12pt]{article}

\usepackage{polyglossia}

\setmainlanguage{english}
\setotherlanguage{hebrew}

\newfontfamily{\englishfont}{EB Garamond}[Ligatures=TeX]

\newfontfamily{\hebrewfont}{Raanana}[Script=Hebrew]
\newfontfamily{\hebrewfontsf}{Raanana}[Script=Hebrew]
\newfontfamily{\hebrewfonttt}{Raanana}[Script=Hebrew]


\title{Using Hebrew Fonts on Overleaf with polyglossia \\\texthebrew{דוגמא לגופני ברירת מחדל}}
\author{Foo}

\begin{document}

\maketitle

I don't know why it is doing this --- but  I don't like it.

\end{document}

ingrese la descripción de la imagen aquí

Pero es mucho mejor usarlo \setmainfont.

\documentclass[12pt]{article}

\usepackage{polyglossia}

\setmainlanguage{english}
\setotherlanguage{hebrew}

\setmainfont{EB Garamond}

\newfontfamily{\hebrewfont}{Raanana}[Script=Hebrew]
\newfontfamily{\hebrewfontsf}{Raanana}[Script=Hebrew]
\newfontfamily{\hebrewfonttt}{Raanana}[Script=Hebrew]


\title{Using Hebrew Fonts on Overleaf with polyglossia \\\texthebrew{דוגמא לגופני ברירת מחדל}}
\author{Foo}

\begin{document}

\maketitle

I don't know why it is doing this --- but  I don't like it.

\end{document}

Respuesta2

Como mencionaste babel, en caso de que decidas seguir así, aquí te explicamos cómo hacerlo:

\documentclass[12pt]{article}

\usepackage[english, bidi=default]{babel}

\babelfont{rm}{EB Garamond}

\babelfont[hebrew]{rm}{Hadasim CLM}
\babelfont[hebrew]{sf}{Miriam CLM}
\babelfont[hebrew]{tt}{Miriam Mono CLM}

\title{Using Hebrew Fonts on Overleaf with Babel\\%
  \foreignlanguage{hebrew}{דוגמא לגופני ברירת מחדל}}
\author{Foo}

\begin{document}

\maketitle

I don't know why it is doing this --- but  I don't like it.

\end{document}

ingrese la descripción de la imagen aquí

información relacionada