I don't like placement of subsripts when using unicode math fonts under XeLaTeX. In contrast to CM fonts the subscripts are placed at different vertical positions obviously depending on the depth of preceding symbol. Here is an example: enter image description here

It is produced with the following MWE:

    \setmainfont[Numbers={OldStyle}]{Minion Pro}
   \setmathfont[version=asana]{Asana Math}
   \setmathfont[version=cambria]{Cambria Math}
   \setmathfont[version=lm]{Latin Modern Math}
   \setmathfont[version=xits]{XITS Math}


    Asana Math \mathversion{asana}
    \( \nabla_{\bot}p_{\bot} + \nabla_{\parallel}p_{\parallel} + d_{s}J_{s}  \)

    Cambria Math
    \( \nabla_{\bot}p_{\bot} + \nabla_{\parallel}p_{\parallel} + d_{s}J_{s}  \)

    \( \nabla_{\bot}p_{\bot} + \nabla_{\parallel}p_{\parallel} + d_{s}J_{s}  \)

    Latin Modern
    \( \nabla_{\bot}p_{\bot} + \nabla_{\parallel}p_{\parallel} + d_{s}J_{s}  \)

    XITS Math
    \( \nabla_{\bot}p_{\bot} + \nabla_{\parallel}p_{\parallel} + d_{s}J_{s}  \)

And original PDFLaTeX with Computer Modern fonts yields subscript aligned at same vertical position:

enter image description here


LuaLaTeX has no such "feature":

enter image description here

Q#1: Is it the XeLaTeX bug?

Q#2: Is it possible to instruct unicode-math to align subscripts on same vertial position under XeLaTeX?


2 Answers 2


I experienced a similar problem with superscripts. Searching for a solution I encountered your question.

Problem Description: Just typeset


The alignment is wrong.

Further search, which might contribute to a solution, revealed that:

Q#1 It is not a xelatex bug, because typesetting with eulervm as a math font and the mathspec package does not lead to this behavior. It is also not an error of opentype font metrics, because the above formulae appear correctly in Word 2010 using Cambria Math (this is embarrassing). Therefore, I am led to believe that there is something rotten in the code of the unicode-math package.

Q#2: Reading the documentation of the unicode-math package, I didn't find any way of correcting this behavior except for modifying the source code, which I don't know how to do.

I think that this should be filed as an example of an unwanted behavior (or bug) to the maintainer of the unicode-math package, in order to be corrected in future versions.

Compiling with lualatex cannot be a general solution, because (at least in my case) I need polyglossia's features, as my text involves English, Greek and some Russian text and polyglossia has its problems with lualatex (or the other way around?).

  • 3
    Note, in XeTeX (and LuaTeX) typesetting old math fonts (eulervm etc) and OpenType math fonts takes different code paths, so bugs might exist in the later and not the former. Jan 16, 2012 at 17:43
  • 1
    In fact, you can run lualatex over Russian text: try using babel instead of polygrlossia, but substitute russianb.ldf (Russian Language Definition file) that came with babel by this one: tug.ctan.org/pkg/russian. Jan 18, 2012 at 10:15

There is already a pending bug report for this issue in the XeTeX bug tracker. Unfortunately, it hasn't been addressed for more than a year.


You must log in to answer this question.

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