[pdftex] Regression: Wrong spacing with explicit space character of different font
Heiko Oberdiek
heiko.oberdiek at googlemail.com
Wed May 21 22:11:21 CEST 2014
Hello,
the following TeX file for iniTeX causes a weird space between "@" and
"s", although the width of the box in between is explicitly set to zero.
This happens with PDF mode of pdfTeX, version:
3.14159265-2.6-1.40.15 (TeX Live 2014)
DVI mode works fine, as older versions:
3.1415926-2.5-1.40.14 (TeX Live 2013)
3.1415926-2.4-1.40.13 (TeX Live 2012)
3.1415926-1.40.10-2.2 (TeX Live 2009)
(Also LuaTeX or XeTeX are not affected.)
Test file for reproducing:
% test.tex
\catcode`\{=1
\catcode`\}=2
\showboxdepth=1000
\showboxbreadth=1000
\tracingonline=1
\font\ph=phvr8r
\font\rm=cmr10
\setbox0=\hbox{%
\rm a@\hbox to 0pt{\ph\char32\hss}srv.com%
}
\scrollmode\showbox0
\shipout\copy0
\csname @@end\endcsname\end
Run with:
pdftex -ini -output-format=pdf test
The result of \showbox is fine:
.\rm @
.\hbox(0.0+0.0)x0.0, glue set - 2.77989fil
..\ph
..\glue 0.0 plus 1.0fil minus 1.0fil
.\rm s
But the PDF code is not (reformatted):
BT
/F2 9.9626 Tf
72 72 Td
[(a@)] TJ
/F1 9.9626 Tf
12.73 0 Td
[(\040)] TJ
/F2 9.9626 Tf
[(srv.com)] TJ
ET
Older versions of pdfTeX generates instead (reformatted):
BT
/F2 9.9626 Tf
72 72 Td
[(a@)] TJ
/F1 9.9626 Tf
12.73 0 Td
[(\040)] TJ
/F2 9.9626 Tf
0 0 Td
[(srv.com)] TJ
ET
Thus "0 0 Td" is missing in the current pdfTeX version.
The problem is quite serious, already a simple document such as
\documentclass{article}
\begin{document}
\noindent
\rlap{\textbf{Hello}}World
\end{document}
fails, "Hello" does not overlap "World".
Yours sincerely
Heiko Oberdiek
PS:
http://www.tug.org/applications/pdftex/
is quite out of date. Also the bug report
address at sarovar does not seem to work
anymore.
More information about the pdftex
mailing list