3

How can I get the dots in the correct position:

\font\test="XITS Math:script=math;mapping=italic" \skewchar\test=127
\XeTeXmathchardef\beta="0"1`β
\def\ddot{\XeTeXmathaccent"7"1"0308}
\textfont1=\test
$\ddot\beta$
\bye

enter image description here vs. default CMI: $\ddot\beta$\bye: enter image description here

morbusg
  • 25,490
  • 4
  • 81
  • 162

3 Answers3

2

It seems to be a bug in XITS Math, as with Asana Math or Latin Modern Math it comes out right (and with no setting of the \skewchar).

Here is with Asana Math, I've added char U+1D5A0 for comparison

enter image description here

egreg
  • 1,121,712
  • Thanks; I could've sworn it was working correctly with an earlier version. I'll wait a while before accepting, if you don't mind. – morbusg Jul 02 '11 at 17:44
  • I don't remember to have seen this before; however one should recall that "XITS Math" is just an interim release. – egreg Jul 02 '11 at 17:47
  • Oh, almost forgot: Is there something I can do to correct with with TeX (because I have another font with the same problem)? – morbusg Jul 02 '11 at 18:03
  • $\skew3\ddot\beta$ seems to work. – egreg Jul 02 '11 at 18:14
2

Looks like a XeTeX bug, LuaTeX give correct result:

\input ifxetex.sty
\ifxetex
  \XeTeXmathchardef\beta="0"1"1D6FD
  \def\ddot{\XeTeXmathaccent"7"1"0308}
\else
  \input luaotfload.sty
  \Umathchardef\beta="0"1"1D6FD
  \def\ddot{\Umathaccent"7"1"0308}
\fi
\font\test="XITS Math:script=math"
\textfont1=\test
$\ddot\beta$
\bye

When run with luatex I get (the same with MS Office 2007):

luatex output

BTW, \skewchar has no use in OpenType math fonts, so setting it makes no difference. Also the /I in your definition makes no sense either sense XITS Math comes only in regular style and there is no separate italic font, {Xe,Lua}TeX will waste time searching for non-existent then fall back to the regular one.

Update: The XeTeX bug has been fixed in 0.9998 (TeX Live 2012) version.

  • Thanks, I noticed the excess "/I" after posting, but was lazy updating the question. :-) – morbusg Jul 02 '11 at 19:38
  • I get wrong results with LuaTeX, Version beta-0.63.0-2010091123 (TeX Live 2010), correct with LuaTeX, Version beta-0.70.1-2011062107 (rev 4277) (TeX Live 2011 test). – egreg Jul 02 '11 at 19:40
  • @egreg, IIRC 0.63 have several math accent related bugs that got fixed in some later version. – خالد حسني Jul 02 '11 at 19:50
  • I see; it's quite surprising that Asana Math doesn't give problems with XeTeX, while XITS Math does. – egreg Jul 02 '11 at 20:00
  • @egreg: not much of surprise to me, it is not the first time I hit some obscure bug only triggered by my fonts that does not show anywhere else, if anyone knows a version of XITS that does not show this, I may try to see what change I did that might have caused it. – خالد حسني Jul 02 '11 at 20:05
  • Strange thing: when I try \dot in LuaLaTeX 0.70 (TeX Live 2011) I get an error that I don't get with 0.63 (TeX Live 2010) although \listfiles shows no difference: \l_um_growing_accents_bool undefined. – egreg Jul 03 '11 at 12:23
  • @egreg: looks like a unicode-math bug, AFAIK it was fixed while ago (you may not see it with 0.63 because that code path is not used there), try updating to latest version of unicode-math. – خالد حسني Jul 03 '11 at 14:10
0

Perhaps you should also try this one:

In the preamble put:

\newcommand{\std}[1]{\overset{\:\mbox{\huge .\!.}}{#1}}

in the text put

\std{\beta}

With this new command for second time derivative you may easily control the location of the double-dot. For example, you may replace \: by \; or \, etc.

user1999
  • 1,464