[luatex] PDF outlines in Lua mode

Patrick Gundlach patrick at gundla.ch
Sat Oct 20 20:27:12 CEST 2018


Hello all,

I came across a question on tex.stackexchange which I tried to answer (because I like to implement this myself).

https://tex.stackexchange.com/q/294883/243

it is about setting PDF outlines (bookmarks) in pure Lua mode without \pdfoutline 


I was starting with a PDF destination set with a whatsit node:

d = node.new("whatsit","pdf_dest")
d.named_id = 0
d.dest_type = 0
d.dest_id = 1234
node.write(d)

this writes, if I remember correctly, a destination object such as "[3 0 R/XYZ 133.768 707.016 null]"

To build an outline I would use a PDF object such as 

<<
  /D 12 0 R
  /S /GoTo
>>

but how would I find out the object number of the pdf_dest node above?

(I guess that there will be follow-up questions, but this is the first question)

Patrick





More information about the luatex mailing list