[XeTeX] bug using \underbrace with unicode-math package

Daniel Greenhoe dgreenhoe at gmail.com
Mon Sep 12 14:53:31 CEST 2011


Hi Philip,

Thank you very much for your suggestion. I did try what you said, but
it doesn't fix the problem on my system. I now get three rotated
question marks under the "xyz" and still no underbrace.

My test file and output can be downloaded from here:
  http://banyan.cm.nctu.edu.tw/~dgreenhoe/groups/test_underbrace.tex
  http://banyan.cm.nctu.edu.tw/~dgreenhoe/groups/test_underbrace.pdf

Dan

On Mon, Sep 12, 2011 at 6:15 AM, Philip TAYLOR (Webmaster, Ret'd)
<P.Taylor at rhul.ac.uk> wrote:
> Sorry, the message became double-spaced (copy-and-paste
> from TeXworks) -- I will try a second time.
>
>
>
>
> \documentclass{article} \RequirePackage{amsmath}
> \RequirePackage{unicode-math} \setmathfont{xits-math.otf}
>
> \def\midshift#1{
> \setbox0=\hbox{#1}\dimen0=\ht0\advance\dimen0by+\dp0\advance\dimen0by-1ex
> \lower.5\dimen0\box0 }
>
> \def\rotatebrace#1{%
> \leavevmode\setbox0=\hbox{#1}\rlap{%
> \kern.5\wd0\dimen0=\ht0\advance\dimen0by-\dp0%\advance\dimen0by+1ex%
> \raise.5\dimen0\hbox{\special{x:gsave}\special{x:rotate 90}}}%
> \box0\special{x:grestore}}
>
> \XeTeXmathchardef\bracelu = 0 3 `\⎧
> \XeTeXmathchardef\bracemu = 0 3 `\⎨
> \XeTeXmathchardef\braceru = 0 3 `\⎩
> \XeTeXmathchardef\bracebar = 0 3 `\⎪
> \XeTeXmathchardef\braceld = 0 3 `\⎫
> \XeTeXmathchardef\bracemd = 0 3 `\⎬
> \XeTeXmathchardef\bracerd = 0 3 `\⎭
>
> \def\upbracefill{%
> \setbox0=\hbox{\lower.64ex\hbox{\rotatebrace{\midshift{$\bracemu$}}}}\ht0=.1\wd0\dp0=0pt%
> \setbox1=\hbox{\lower.64ex\hbox{\rotatebrace{\midshift{$\bracelu$}}\kern-.2em}}\ht1=.1\wd0\dp1=0pt%
> \setbox2=\hbox{\lower.64ex\hbox{\rotatebrace{\midshift{$\bracebar$}}}}\ht2=.1\wd0\dp2=0pt%
> \setbox3=\hbox{\lower.64ex\hbox{\kern-.2em\rotatebrace{\midshift{$\braceru$}}}}\ht3=.1\wd0\dp3=0pt%
> \box1\cleaders\copy2\hfill\box0\cleaders\box2\hfill\box3}
>
> \def\downbracefill{%
> \setbox0=\hbox{\lower.64ex\hbox{\rotatebrace{\midshift{$\bracemd$}}}}\ht0=.1\wd0\dp0=0pt%
> \setbox1=\hbox{\lower.64ex\hbox{\rotatebrace{\midshift{$\braceld$}}\kern-.2em}}\ht1=.1\wd0\dp1=0pt%
> \setbox2=\hbox{\lower.64ex\hbox{\rotatebrace{\midshift{$\bracebar$}}}}\ht2=.1\wd0\dp2=0pt%
> \setbox3=\hbox{\lower.64ex\hbox{\kern-.2em\rotatebrace{\midshift{$\bracerd$}}}}\ht3=.1\wd0\dp3=0pt%
> \box1\cleaders\copy2\hfill\box0\cleaders\box2\hfill\box3}
> %
>
> \setmathfont {XITS Math}
>
> \begin {document}
>
> $$ \underbrace{xyz} $$
>
> \end{document}
>
>
> Philip Taylor
>
>
> --------------------------------------------------
> Subscriptions, Archive, and List information, etc.:
>   http://tug.org/mailman/listinfo/xetex
>
>



More information about the XeTeX mailing list