PDF creators, extractors, and editors tested
Pdf2svg
The pdf2svg tool relies on Poppler and Cairo to convert some or all PDF pages into SVG format [8]. The SVG files can then be approximately disassembled or edited with Inkscape. Pdf2svg (v0.2.2) chops up text with no discernible rules and dumps each snippet into a separate text box.
That said, the layout remained remarkably intact in all the test documents. The same is true of vector graphics; pdf2svg stores bitmap images within the generated SVG file. Only the color gradients in the PDF files generated by Scribus disappeared; the bars on the cover page, for example, came out solid red. The tool cannot handle password-protected PDF documents.
Inconsistent All-Rounder
Although these test documents did not cover all aspects of PDF exports and imports, they definitely provided some interesting results (see Table 1). Inkscape, LibreOffice Writer, and Scribus by no means offer the functionality and capabilities of Adobe Acrobat, but they do generate standards-compliant and pretty good PDF documents.
Table 1
Function Test – Read and Edit PDFs
Creator | Inkscape | LibreOffice Writer | Scribus | InDesign |
---|---|---|---|---|
Editor |
||||
Inkscape |
Good |
Good |
Good |
Good |
LibreOffice Draw |
Satisfactory |
Good |
Satisfactory |
Satisfactory |
Scribus |
Poor |
Poor |
Poor |
Poor |
Program |
||||
gPDFText |
Good |
Good |
Good |
Good |
Mutool |
Good |
Good |
Good |
Good |
Pdftotext |
Good, can keep layout |
Good, can keep layout |
Good, can keep layout |
Good, can keep layout |
Pdfimages |
Good |
Good |
Good |
Good |
Pdftohtml |
Satisfactory |
Satisfactory |
Satisfactory |
Satisfactory |
Pdf2svg |
Good |
Good |
Good |
Good |
When it came to importing PDF documents, major differences were revealed. Inkscape imported documents without complaint; the layout is preserved and the text remained editable – although not in a particularly convenient way. However, the drawing program can only open one page at a time. LibreOffice best understands the PDF files it generates itself; with other PDFs, users may be faced with a slightly damaged layout. In our lab, the Scribus desktop publishing program failed to open even one PDF file without error and was relegated from the import league in the first round.
Lean Specialists
The small special tools for the command line did better. With pdftotext, for example, the layout may be history after conversion, but at least the text was kept in full. However, if somebody stored the text in the PDF as paths, pdftotext is powerless. The same applies to gPDFText, which produces a huge block of text. The text from columns are also nested within each other.
Mutool extracts all images and fonts from the PDFs. In terms of fonts, you simply have to hope that the author embedded the complete font. The probability for this is highest in documents from LibreOffice and Inkscape. Mutool always outputs images in PNG format. Pdfimages takes over here, which – exactly like Mutool – extracts all the bitmap images from a PDF.
If you want to extract vector graphics from a PDF, your only option is to turn to pdf2svg and use Inkscape for cutting and downstream processing. pdftohtml is only usable for simple PDF documents. Here, users would fare better to extract the items with the other tools and then manually assemble them into an HTML document.
Infos
- Openclipart: http://openclipart.org
- "PHP-CLI" by Tim Schürmann, Linux Magazine, issue 140, pg. 42: http://www.linux-magazine.com/Issues/2012/140/PHP-CLI
- "Charly's Column: Backup2l" by Charly Kühnast, Linux Magazine, issue 46, pg. 46: http://www.linux-magazine.com/Issues/2014/159/Charly-s-Column-Backup2l
- gPDFText: http://gpdftext.sourceforge.net
- MuPDF: http://www.mupdf.com
- PostScript font formats: http://en.wikipedia.org/wiki/PostScript_fonts
- Poppler: http://poppler.freedesktop.org
- Pdf2svg: http://www.cityinthesky.co.uk/opensource/pdf2svg/
« Previous 1 2 3 4
Buy this article as PDF
(incl. VAT)
Buy Linux Magazine
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Support Our Work
Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.
News
-
Canonical Bumps LTS Support to 12 years
If you're worried that your Ubuntu LTS release won't be supported long enough to last, Canonical has a surprise for you in the form of 12 years of security coverage.
-
Fedora 40 Beta Released Soon
With the official release of Fedora 40 coming in April, it's almost time to download the beta and see what's new.
-
New Pentesting Distribution to Compete with Kali Linux
SnoopGod is now available for your testing needs
-
Juno Computers Launches Another Linux Laptop
If you're looking for a powerhouse laptop that runs Ubuntu, the Juno Computers Neptune 17 v6 should be on your radar.
-
ZorinOS 17.1 Released, Includes Improved Windows App Support
If you need or desire to run Windows applications on Linux, there's one distribution intent on making that easier for you and its new release further improves that feature.
-
Linux Market Share Surpasses 4% for the First Time
Look out Windows and macOS, Linux is on the rise and has even topped ChromeOS to become the fourth most widely used OS around the globe.
-
KDE’s Plasma 6 Officially Available
KDE’s Plasma 6.0 "Megarelease" has happened, and it's brimming with new features, polish, and performance.
-
Latest Version of Tails Unleashed
Tails 6.0 is based on Debian 12 and includes GNOME 43.
-
KDE Announces New Slimbook V with Plenty of Power and KDE’s Plasma 6
If you're a fan of KDE Plasma, you'll be thrilled to hear they've announced a new Slimbook with an AMD CPU and the latest version of KDE Plasma desktop.
-
Monthly Sponsorship Includes Early Access to elementary OS 8
If you want to get a glimpse of what's in the pipeline for elementary OS 8, just set up a monthly sponsorship to help fund its continued existence.