#150 inputting tikz causes strange vertical spacing in plain Tex

closed-fixed
nobody
None
9
2011-10-30
2010-11-08
Jim
No

Using the following plain TeX input

\input tikz

\hrule
\vfill
just a plain line of text in the middle of the page
\vfill
\eject

\end

The line claims it is in the middle of the page, but if I \input tikz
it is not. If I don't \input tikz, the line is (more or less) in the
middle of the page, as expected. Also, when I \input tikz, my page
number goes away.

This is the version of tikz in the texlive 2010 as of Nov 6 (pgf 2.10)

The previous version of pgf/tikz in texlive did not exhibit this misbehaviour.

Discussion

  • Christophe Jorssen

    On ctt, Dan Luecking posted the following comment.

    The fault seems to lie in \pgfutil@EveryShipout@Output, which
    reworks \box255 in a way that changes its height. Its
    definition is in pgfutil-plain.def and consists of

    \def\pgfutil@EveryShipout@Output{%
    \setbox255=\vbox{%
    \setbox0=\hbox{\pgfutil@abe\unhbox\pgfutil@abb
    \pgfutil@abc\global\let\pgfutil@abc\pgfutil@empty}%
    \wd0=0pt%
    \ht0=0pt%
    \dp0=0pt%
    \box0%
    \unvbox255%
    }%
    \pgfutil@@EveryShipout@Org@Shipout\box\@cclv%
    }

    That first line is a problem: since a plain "\vbox{" will have
    its natural height, without stretching any glue, the effects
    of the \vfills are lost. Changing that first line
    \setbox255=\vbox{%
    to
    \setbox255=\vbox to\ht255{%
    will work in the sense that it makes this test succeed, but
    who knows what other traps await the unwary...

    [In case anyone is wondering: I put \tracingmacros1 in front
    of \eject to see if the output routine had been changed, and
    voila.]

     
  • Jim

    Jim - 2010-11-18

    The thread entitled "\input'ing tikz causes strange vertical spacing in plain TeX" in comp.text.tex (1st post Nov 11, 2010) has a couple of suggested solutions. Anyone in the tikz world care to look there, select one, and fix the bug?

    Cheers.

     
  • Jim

    Jim - 2010-11-18
    • priority: 5 --> 9
     
  • Christophe Jorssen

    This should be fixed in the cvs repo.

     
  • Christophe Jorssen

    • status: open --> closed-fixed
     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks