[Dev-luatex] Possible issue with input from external libraries (page break problem?)

Hartmut Henkel hartmut_henkel at gmx.de
Wed Apr 14 20:58:40 CEST 2010


On Wed, 14 Apr 2010, Hans Hagen wrote:
> On 14-4-2010 9:45, Taco Hoekwater wrote:
> > Taco Hoekwater wrote:
> > >
> > > I don't think this is supposed to happen, but please send me the
> > > pdf for a closer look and, if possible, a source to go with it
> > > that uses a lua library that is available to me. I am on linux,
> > > but lxp should work for me as well. I can even try to run the test
> > > under wine.
> >
> > I've looked at your file, and it is not related to external
> > libraries nor the luatex extensions at all: The problem is the
> > \immediate\pdfximage.
> >
> > You can get the exact same problem in pdftex with this input:
> >
> > \pdfoutput=1
> > \immediate\pdfximage width 0.5\hsize {./cow.pdf}
> > \pdfrefximage\pdflastximage
> > \input knuth
> > \input knuth
> > \input knuth
> > \input knuth
> > \input knuth
> > \input knuth
> > \input knuth
> > \bye
> >
> > In both cases, the problem can be fixed by adding a \hbox around the
> > \pdfrefximage. But now I have a question for Hartmut: is this
> > supposed to happen?
>
> definitely looks like a bug to me
>
> \setuppapersize[A4][A1] \setuplayout[location=middle,marking=on]
>
> \starttext
>
> \immediate\pdfximage  width 0.5\hsize {./cow.pdf}
> \dorecurse {3}{\pdfrefximage\pdflastximage}
> \dorecurse{10}{\the\pagetotal\input knuth \par}
>
> \stoptext
>
> the ref'd image whatsit is added to the mvl but the height is not
> added to pagetotal (at least that's what it looks like) due the fact
> that no paragraph is started

but it is so since ancient pdftex times (and i have also stumbled over
it, and since then i'm wrapping \pdfrefximage in a \hbox, as you
suggest). The \pdfrefximage doesn't do any h or v mode change, it's
neutral. And i guess one should keep it like this to avoid
incompatibilities.

Regards, Hartmut



More information about the dev-luatex mailing list