On 4/5/2016 11:40 PM, David Carlisle wrote:
Given
\mathsurround=12pt
\tracingonline1
\setbox0\hbox{a$x$b}
\showbox0
\end
tex shows the size of the mathsurround :
\box0=
\hbox(6.94444+0.0)x40.27086
.\tenrm a
.\mathon, surrounded 12.0
.\teni x
.\mathoff, surrounded 12.0
.\tenrm b
luatex did the same until 0.95 but now it does not log the size of the
extra space:
$ luatex msur
This is LuaTeX, Version beta-0.95.0 (TeX Live 2016)
restricted system commands enabled.
(./msur.tex
\box0=
\hbox(6.94444+0.0)x40.27086, direction TLT
.\tenrm a
.\mathon
.\teni x
.\mathoff
.\tenrm b
! OK.
l.5 \showbox0
Was this change intentional?
no, just a forgotten change in field name (glue spec data moved into
math nodes) and the skip was reported instead, i fixed it so now
\tracingonline1
\nonstopmode
\mathsurroundskip0pt
\mathsurround 0pt
\setbox0\hbox{a$x$b}
\mathsurroundskip 0pt
\mathsurround 10pt
\setbox2\hbox{a$x$b}
\mathsurroundskip20pt plus 3pt minus 3pt
\mathsurround 0pt
\setbox4\hbox{a$x$b}
\mathsurroundskip20pt plus 3pt minus 3pt
\mathsurround 10pt
\setbox6\hbox{a$x$b}
\showbox0
\showbox2
\showbox4
\showbox6
\noindent \box0~nothing \par
\noindent \box2~kern \par
\noindent \box4~glue \par
\noindent \box6~kern+glue\par
gives
> \box0=
\hbox(8.328+0.132)x19.272, direction TLT
.\3>modern-designsize-12pt-rm-tf-0--0 a
.\mathon
.\3>modern-designsize-12pt-mm-mb--1 𝑥
.\mathoff
.\3>modern-designsize-12pt-rm-tf-0--0 b
> \box2=
\hbox(8.328+0.132)x39.272, direction TLT
.\3>modern-designsize-12pt-rm-tf-0--0 a
.\mathon, surrounded 10.0
.\3>modern-designsize-12pt-mm-mb--1 𝑥
.\mathoff, surrounded 10.0
.\3>modern-designsize-12pt-rm-tf-0--0 b
> \box4=
\hbox(8.328+0.132)x59.272, direction TLT
.\3>modern-designsize-12pt-rm-tf-0--0 a
.\mathon, glued 20.0 plus 3.0 minus 3.0
.\3>modern-designsize-12pt-mm-mb--1 𝑥
.\mathoff, glued 20.0 plus 3.0 minus 3.0
.\3>modern-designsize-12pt-rm-tf-0--0 b
> \box6=
\hbox(8.328+0.132)x59.272, direction TLT
.\3>modern-designsize-12pt-rm-tf-0--0 a
.\mathon, glued 20.0 plus 3.0 minus 3.0
.\3>modern-designsize-12pt-mm-mb--1 𝑥
.\mathoff, glued 20.0 plus 3.0 minus 3.0
.\3>modern-designsize-12pt-rm-tf-0--0 b
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | www.pragma-ade.com | www.pragma-pod.nl
-----------------------------------------------------------------