2

I am using polyglossia with English as the main language and Arabic as the other language. I have an enumerate list with the first content of the list being in Arabic followed by a translation in English. The problem is that the number label of the list is on the right as opposed to the left; the latter being my requirement.

Adding a non-breaking space right after \item helps but messes up the alignment.

Here is my MWE,

\documentclass{article}

\usepackage{polyglossia}

\setmainlanguage{english}
\setotherlanguage[numerals=maghrib]{arabic}

\newfontfamily\arabicfont[
Script=Arabic,%
Numbers=Proportional,%
Scale=1.5%
]{Traditional Arabic}

\begin{document}

\begin{enumerate}

\item \begin{Arabic}
        اَلحَمدُ لِلهِ الَّذِي أحيَانَا بَعْدَ مَا أمَاتَنَا وَ إِلَيهِ
        النُّشُورُ
\end{Arabic}

  Praise is to Allāh Who gives us life after He has caused us to die and
to Him is the return.
\end{enumerate}

\end{document}

Here is the current output,

MWE output

1 Answer 1

1

You can embed your Arabic environment within a parbox

\item 
\parbox{\linewidth}{%
\begin{Arabic}
        اَلحَمدُ لِلهِ الَّذِي أحيَانَا بَعْدَ مَا أمَاتَنَا وَ إِلَيهِ
        النُّشُورُ
\end{Arabic}}

A new environment can be used here to simplify code and avoid repeating \parbox

\documentclass{article}

\usepackage{polyglossia}

\setmainlanguage{english}
\setotherlanguage[numerals=maghrib]{arabic}

\newfontfamily\arabicfont[
Script=Arabic,%
Numbers=Proportional,%
Scale=1.5%
]{Traditional Arabic}

\newenvironment{Arabicitem}{\begin{minipage}{\linewidth}\begin{Arabic}}
{\end{Arabic}\end{minipage}}

\begin{document}

\begin{enumerate}

\item \begin{Arabicitem}
        اَلحَمدُ لِلهِ الَّذِي أحيَانَا بَعْدَ مَا أمَاتَنَا وَ إِلَيهِ
        النُّشُورُ
\end{Arabicitem}

  Praise is to Allāh Who gives us life after He has caused us to die and
to Him is the return.
\end{enumerate}

\end{document}
3
  • Is there a way I can automate this? Commented Feb 22, 2017 at 20:47
  • Answer updated.
    – Salim Bou
    Commented Feb 22, 2017 at 21:29
  • Is it possible to align the number with the first line of Arabic text if a paragraph of Arabic text is used? Right now, it centers the number vertically which looks odd. Commented Aug 3, 2017 at 4:30

You must log in to answer this question.

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