Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I was surprised that there is no easy way to remove bookmarks from PDF.
pdftk can't do it, ghostscript same AFAIK, qpdf... and there are no other significant tools that I'm aware of

Easiest for me right now is PDF Mod GUI, which removes bookmarks one by one - user has to click on parent bookmark and press remove, so on for all top level nodes which is silly

Also I know there are probably some Java GUIs that can do it, but I don't want to load java just to remove bookmarks when I need to

I could also accept some programmatic solution, python, perl ...

share|improve this question

2 Answers 2

This worked for me:

pdf2ps mypdf.pdf

I get mypdf.ps, I rename it to mypdf2.ps

ps2pdf mypdf2.ps

The mypdf2.pdf file that I get has no bookmarks

Both programs come with the ghostscript package

share|improve this answer
    
Despite thrashing my HD, calling ghostscript twice is slower and more memory intensive then loading worse java GUI to handle the problem. It's easier to just print the PDF to another PDF as I'll at least get PDF product with text layer, unlike your example, and faster –  zetah Dec 21 '11 at 0:56

If you have Adobe Acrobat Pro you can remove all the bookmarks of your front PDF document using the following simple AppleScript:

tell application "Adobe Acrobat Pro"
    delete bookmarks of document 1
end tell
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.