[luatex] pdf_dest node explained

Paul Isambert zappathustra at free.fr
Thu Jun 30 11:30:56 CEST 2011


Le 30/06/2011 11:19, Taco Hoekwater a écrit :
>
> On 06/30/11 10:48, Patrick Gundlach wrote:
>
>> what is the objnum?
> pdf object number (if already written). This is needed internally

It seems to stick to 0, though. Is that because its numbers is 
determined at shipout only? But then it's useless, since after shipout 
you can't retrieve it... I suppose the object number is reserved in 
advance, but the field here isn't correctly updated? See:

\output{
     \directlua{
         local dest = tex.box[255].head.next.head
         while not(dest.id == 8 and dest.subtype == 19) do
             dest = dest.next
          end
          texio.write_nl(dest.objnum)}
\shipout\box255
}

abc \pdfdest num 1 fitr
\bye

This prints 0, even though 0 is an illegal object number (and the 
destination is in object 5 anyway).



Also, totally unrelated: with object streams, pdfTeX signals the 
objects' numbers in a comment:

% 2 0 obj
...
% 8 0 obj
...
% 25 0 obj
...

LuaTeX does so too, but the comment is at the end of the last line of 
the previous object, which is quite unreadable:
% 2 0 obj
... % 8 0 obj
... % 25 0 obj
...

I think somebody forgot a carriage return, or is that on purpose?

Best,
Paul


More information about the luatex mailing list