3

(Note: See EDIT below that rules out both stackengine and standalone as the culprit)

Input:

\documentclass{standalone}
\usepackage{unicode-math}
\usepackage{stackengine}\stackMath
\begin{document}
\(\bigl[
,
  \mathchoice%
  {}%
  {}%
  {}%
  {\stackunder{\scriptscriptstyle a}{}}
\bigr]\)
\end{document}

We expect the output [,] with same-size vertically aligned brackets. However, the output is as follows:

output when running xelatex

The brackets have different sizes and irregular vertical placement, which is wrong: they should have the same size and be vertically aligned. Using \Big, \bigg, etc. instead of \big produces similarly erroneous output. Removing \usepackage{unicode-math}, or, \scriptscriptsize, or, a, or \stackunder doesn't trigger the bug any more. The compilation was done with the following software versions:

  • XeTeX, Version 3.14159265-2.6-0.99996 (TeX Live 2016/Debian) (preloaded format=xelatex 2017.4.2)
  • LaTeX2e <2017/01/01> patch level 3
  • standalone 2015/07/15 v1.2 (NOT responsible)
  • unicode-math 2015/09/24 v0.8c
  • stackengine 2016/10/04 v4.00 (NOT responsible)

Who is the culprit and what to do?


EDIT by S.B. Segletes

The stackengine package is shown not to be the culprit, by the following MWE, which produces the identical wrong result without the use of stackengine. Changing standalone to article also does not correct the issue.

\documentclass{standalone}
\usepackage{unicode-math}
\begin{document}
\(\bigl[
,
  \mathchoice%
  {}%
  {}%
  {}%
  {\hbox{$\scriptscriptstyle a$}}
\bigr]\)
\end{document}
  • the brackets are the same size for me with xelatex in texlive 2017 – David Carlisle Jun 16 '17 at 22:32
  • 1
    I'm pretty sure it's again this one: Why is the fraction off the math axis in XeTeX? Fontdimens have been messed up (and are still not entirely correct) in XeTeX before TL2017. Upgrade your TeXlive and you should be fine or switch to LuaTeX. – Henri Menke Jun 17 '17 at 2:02
  • 1
    @LeonMeier I think it was a fix in the xetex binary itself so will not be available in a texlive 2016 update – David Carlisle Jun 17 '17 at 7:44
  • I can also confirm this behavior for my MikTeX installation. Not sure which packages or configurations need updating... – Steven B. Segletes Jun 19 '17 at 10:41
  • 1
    I have provided the MWE that excludes stackengine as the culprit. – Steven B. Segletes Jun 19 '17 at 15:19
1

This used to be an issue with XeTeX up to version 3.14159265-2.6-0.99996 (the one in TeX Live 2016). It doesn't happen with XeTeX 3.14159265-2.6-0.99998 (included in TeX Live 2017).

This is the output of the original code (including stackengine) with the new release

enter image description here

This is the output of the reduced code with the new release

enter image description here

  • Would you happen to know how to tell MikTeX to update XeTeX? – Steven B. Segletes Jun 19 '17 at 17:17
  • 1
    @StevenB.Segletes Of course not. ;-) – egreg Jun 19 '17 at 17:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy