4

I am trying to get an article formatted for someone who needs to use English and German but with two words each of Hebrew and Arabic. It appears that babel/hebrew requires inputenc, which makes it unusable in XeLaTeX, my preferred engine.

What is the current advice for documents in western European alphabets with only a tiny amount (a few words) in right-to-left alphabets? It can be arranged that the RTL text is never in a position needing hyphenation.

2

2 Answers 2

6

Use polyglossia. Here is an example of how you can do it. Change the fonts as you see fit.

Simply encase the Hebrew or Arabic text in \begin{hebrew} ... \end{hebrew} or \begin{Arabic} ... \end{Arabic}, respectively.

%XeLaTeX
\documentclass{book}

\usepackage{polyglossia}
    \setdefaultlanguage{english}
        \newfontfamily\englishfont[Ligatures=NoCommon]{Linux Libertine O}
    \setotherlanguage{hebrew}
        \newfontfamily\hebrewfont[Script=Hebrew]{Arial}
    \setotherlanguage{arabic}
        \newfontfamily\arabicfont[Script=Arabic]{Times New Roman}


\begin{document}

Thank You

\begin{hebrew} תודה \end{hebrew}

\begin{Arabic} شكرا \end{Arabic}

\end{document}

enter image description here

0
2

babel can deal with both Arabic and Hebrew and your requirements fit exactly into what babel calls a ‘mostly monolingual document’. For a few words, you don’t need to declare explicitly the languages – just set the font up in the preamble and switch to Hebrew or Arabic where necessary:

\documentclass{article}

\usepackage[english, bidi=bidi]{babel}
\babelfont[hebrew, arabic]{rm}{FreeSerif} 
\babeltags{he = hebrew, ar = arabic} % Just for convenience

\begin{document}

Maimonides, the Andalusi Jewish philosopher, authored works in
Judeo-Arabic—Arabic written in Hebrew script—including his famous
\textit{The Guide for the Perplexed} (\texthe{דלאלת אלחאירין‎},
\textar{دلالة الحائرين‎}, \textit{Dalālat al-ḥāʾirīn}).

\end{document}

enter image description here (Text from Wikipedia.)

You must log in to answer this question.

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