[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


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

  \rm a@\hbox to 0pt{\ph\char32\hss}srv.com%
\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
    ..\glue 0.0 plus 1.0fil minus 1.0fil
    .\rm s

But the PDF code is not (reformatted):

      /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

Older versions of pdfTeX generates instead (reformatted):

      /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

Thus "0 0 Td" is missing in the current pdfTeX version.

The problem is quite serious, already a simple document such as


fails, "Hello" does not overlap "World".

Yours sincerely
  Heiko Oberdiek

is quite out of date. Also the bug report
address at sarovar does not seem to work

More information about the pdftex mailing list