Conversion Toolspdflatex, pdfpages - import pdf with bookmarks

Information and discussion about output converters related to LaTeX (e.g. dvips, ps2pdf, ...)
Post Reply
SkyHiRider
Posts: 11
Joined: Mon Oct 18, 2010 2:14 pm

pdflatex, pdfpages - import pdf with bookmarks

Post by SkyHiRider »

I'm using pdflatex to generate pdf files and the pdfpages class to import pdf files into my document (\includepdf).

When a pdf file is imported it looses all of its bookmarks that were present in the original file. Is there a way to preserve the bookmarks in the new file?
Last edited by SkyHiRider on Sat May 14, 2011 6:51 pm, edited 1 time in total.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org
LaTeX Beginner's Guide LaTeX Cookbook LaTeX TikZ graphics TikZによるLaTeXグラフィックス
User avatar
Stefan Kottwitz
Site Admin
Posts: 10290
Joined: Mon Mar 10, 2008 9:44 pm

pdflatex, pdfpages - import pdf with bookmarks

Post by Stefan Kottwitz »

Hi,

pax can help to bring the bookmarks, hyperlinks and other PDF annotations to the new file.

Stefan
LaTeX.org admin
SkyHiRider
Posts: 11
Joined: Mon Oct 18, 2010 2:14 pm

Re: pdflatex, pdfpages - import pdf with bookmarks

Post by SkyHiRider »

Thanks, didn't know about pax. Now just to find a way of running it on a Linux distro with Texlive installed.
SkyHiRider
Posts: 11
Joined: Mon Oct 18, 2010 2:14 pm

pdflatex, pdfpages - import pdf with bookmarks

Post by SkyHiRider »

Answer to my previous question for future readers: use the pdfannotextractor command (works on Ubuntu).

If you're getting a weird error, use pdfannotextractor --install (this should fix the perl dependencies and automatically install all the needed packages).

Have a new issue: How do I remove pdf hyperling highlighting in the newly created pdf? (every PDF document link has a red border and every outgoing link has a cyan border)
User avatar
Stefan Kottwitz
Site Admin
Posts: 10290
Joined: Mon Mar 10, 2008 9:44 pm

pdflatex, pdfpages - import pdf with bookmarks

Post by Stefan Kottwitz »

Hi,
SkyHiRider wrote:Have a new issue: How do I remove pdf hyperling highlighting in the newly created pdf? (every PDF document link has a red border and every outgoing link has a cyan border)
this can be done by

Code: Select all

\hypersetup{colorlinks=false}
or set this as option to hyperref.

Btw. for new questions please open a new thread and mark the earlier thread as solved. This can be done by editing your first post in this thread (the question) and choosing the checkmark symbol as topic icon. So it's easier to see still open questions. Thanks for that!

Stefan
LaTeX.org admin
SkyHiRider
Posts: 11
Joined: Mon Oct 18, 2010 2:14 pm

pdflatex, pdfpages - import pdf with bookmarks

Post by SkyHiRider »

It was actually

Code: Select all

\hypersetup{colorlinks=true}
that fixed it. Thanks!
User avatar
Stefan Kottwitz
Site Admin
Posts: 10290
Joined: Mon Mar 10, 2008 9:44 pm

pdflatex, pdfpages - import pdf with bookmarks

Post by Stefan Kottwitz »

Or use

Code: Select all

\hypersetup{
  colorlinks=false,
  pdfborder={0 0 0}
}
if you want to remove both color and frames.

Stefan
LaTeX.org admin
Post Reply