[pdftex] pdfpageattr and reuse of annotations

Heiko Oberdiek oberdiek at uni-freiburg.de
Thu Nov 21 11:22:35 CET 2002


On Thu, Nov 21, 2002 at 05:38:28PM +1100, Leo Brewin wrote:

> \pdfpageattr{/Annots [\the\source\space 0 R]}
> 
> on each subsequent page (were "source" is the pdf object number for the 
> original annotation). (Well, I actualy do a little bit more to force 
> pdftex to expand \the\source\space but thats by the side).

* limit the range of pages where this command is active:
  \begingroup
    \pdfpageattr{...}
    <page break>
  \endgroup

* at the next page: filter the contents of \pdfpageattr and
  remove unwanted stuff. See package hyperref, thumbpdf, pdflscape, ...

> If I have other annotations on the page (say from a \href) then pdftex 
> generates two separate /Annots in the pdf page object, for example
> 
> 6 0 obj <<
> /Type /Page
> /Contents 25 0 R
> /Resource 24 0 R
> /MediaBox [0 0 612 792]
> /Annots [22 0 R]         <--- generated by \pdfpageattr above
> /Parent 31 0 R
> /Annots [17 0 R]         <--- generated by \href
> >> endobj
> 
> Is this valid pdf code?

Avoid it. It depends on the PDF interpreter which one is selected.

Yours sincerely
  Heiko <oberdiek at uni-freiburg.de>



More information about the pdftex mailing list