Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Do I need to use an extra program (pax) in order to bookmark labels of merged pdfs?

For my application, I use KOMA-Script for the letter and moderncv for the CV. Therefore, I have to use two different document classes, so I have to merge my pdfs. The table of content or the bookmarks of my CV sections are lost. It is possible to refer to complete pages while merging PDFs, but am I somehow manually able to refer to labeled sections without the hassle of an external program?

Update: Added a picture that shows how bookmarks refer to the document structure which is finer than pages. I don't need to reuse these bookmarks, adding them manually in the merger.tex would be great, too.

modernCV example

share|improve this question
2  
Please show us an example what you how want to refer. Usually I have in the letter at the end a part like enclosed CV, Reference (German: Zeugnis) 1, Reference 2. In this case I do not need refs ... –  Kurt Apr 8 '13 at 21:44
    
As your letter is probably not very ToC-intensive, I would go the other way round: Take the CV as the master document and embed the cover letter's PDF with pdfpages as the first page. The \includepdf command provides an interface to create a ToC entry for the embedded page. –  Daniel Apr 9 '13 at 5:32
    
Actually the same idea also crossed my mind ... but then I was curious if there's a clean, unlimited solution :-) Is there a way to group all of the bookmarks shown above under a bookmark CV? –  Stefan K. Apr 9 '13 at 11:51

1 Answer 1

up vote 5 down vote accepted

Yes, you need an external program, although I've heard rumors that ConTeXt mkIV can do this.

The reason why this problem (merging of bookmarks of included pdfs) is mostly unsolved is that it is hard in PDF:

  1. The bookmarks are specified completely separate from the page contents.
  2. The target positions of the bookmarks are specified completely separate from the page contents.
  3. The internal names of the bookmarks are specific to a document.

In short: Bookmarks and labels seem to have been designed later in PDF, when the page content was already well defined.

So while inclusion of page contents for PDF is relatively simple (convert the page into an XObject), inclusion of bookmarks

  1. has to handle a separate structure in the PDFs,
  2. calculate the new target positions of the bookmarks (they may be rotated, scaled and displaced),
  3. and somehow merge the namespaces of the included PDFs and the main document.

AFAIK nobody has solved those problems for all cases; I believe ConTeXt handles only the "simple"(usual) cases. I know of no program that handles all cases (I doubt that e.g. Adobe InDesign does).

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.