I have an issue with xelatex+bidi where parentheses sometimes are reversed on multilingual lines. A minimal example is included:



\newfontfamily\hebrewfont[Script=Hebrew,Scale=1]{Times New Roman}



סעיף שנגמר עם עברית.

$1\neq 2$.

בסעיף העוקב רואים בעיה.

משפט בעברית (עם הערה שנגמרת ב- English).


reversed parenthesis

Note how the 2nd item ending with a math environment 'switched' the context to English, so that the next item has its label parenthesis reversed. The same occurs when a closing parenthesis is preceded by English text.

Questions here and here claim that adding Script=Hebrew in my \hebrewfont should've fixed the issue, but it doesn't. Also, I've seen an indication that this issue might be related to polyglossia and the \if@Latin boolean, but I'm not sure how to fix that systemically.

  • 2
    This seems to be font related. If I run your document with David CLM the enumeration is correct. (My version of Times New Roman doesn't seem to have Hebrew, so I can't test with that.) Also, you need to set the other language to English and then wrap the English part in \textenglish{} to get the parentheses right in the last sentence.
    – Alan Munn
    Nov 1, 2016 at 20:52
  • This seems to work fine on texlive 2017 on a mac. Perhaps a bug has been fixed in the meantime. Aug 1, 2017 at 13:40
  • @AndrewSwann does it? Using vanilla texlive 2017 (XeTeX 3.14159265-2.6-0.99998 (TeX Live 2017)) on Ubuntu Xenial I still get the reversed parenthesis on the following list item after an item concluding in English text (or inline math mode). However, as AlanMunn said, changing font to David CLM does take care of that. Also, his remark regarding adding \setotherlanguage{english} to the preamble and enclosing English text in \textenglish{} solves the problem demonstrated after the list. Aug 1, 2017 at 13:54
  • That seems to be further confirmation that it is some font issue. Aug 1, 2017 at 14:26
  • My thoughts exactly. Aug 1, 2017 at 14:27


Browse other questions tagged or ask your own question.