A plugin to export layers in GIMP file to single pdf file

Update: there is another plugin that export Layers to single multiple pages PDF. You can get the plugin here: http://registry.gimp.org/node/27987. Which one is better? Well, they both work fine for me and are equally easy to use. So just try them out both to see which one works best for you.

A while back I wrote about two possible ways to export multiple layers in GIMP to one pdf file using third-party tools. But it turns out there is an much easier solution as Nevar pointed out in the comments on that blog post. The ‘Export Layers as PDF’ plugin for GIMP. You can get the plugin from the Gimp plugin registry. See here for instructions how to install the plugin.

After installing you need to restart GIMP after which you can find the new function in the file menu (see screenshot).

GIMP with an image with two layers and the new menu item to export this image with layers to a pdf

GIMP with an image with two layers and the new menu item to export this image with layers to a pdf

In the export window, you need to enter the name and location of the file. Don’t forget to add .pdf as extension, otherwise it will save the layers as separate png files. You furthermore have the option to save visible layers only and to flatten the image (which would give you the same result as the normal way to export your image to pdf).

It works like a charm, as you can see in the screenshot below. Just be aware that it, unfortunately, does not seem to export text. What I did was just merging the text to a new layer before exporting. It has been tested on Linux so your luck may vary on other operating systems.

A pdf created from an image with two layers in GIMP using the 'Export Layers as PDF' plugin

A pdf created from an image with two layers in GIMP using the ‘Export Layers as PDF’ plugin

11 thoughts on “A plugin to export layers in GIMP file to single pdf file

  1. Pingback: Episode 188: The Book | Meet the GIMP!

    • Initially I was thinking it didn’t work (neither another one that does the same thing), but turns out that, for me at least, it needed to be on the “plugins” folder, not on the “scripts” (now both work). Other possibility is that the script file isn’t set as executable (on linux), or that you don’t have “convert”/imagemagick set on Gimp’s environment path, on windows.

  2. At least on Mac OsX systems there’s non need for plug-ins.
    Import PDF file as multiple layer, do the modifies, then save single pages as JPEG file or other graphic format, or even as PDF format (single pages only), choosing a new folder for your convenience. Remember to numerate images progressively.
    On Mac 10.7 onward there is an easy option in “Automator” app which can merge in a single PDF file many pdf images. Or even another Automator app which can output a single PDF file from many images files.
    Of course, you may want to specify the Automator application by choosing “obtain files from Finder”, then “set files progressively” then “open the resulting file with proper application” (that is “Preview”, by default)
    Now you’ll have on the screen the PDF (in Preview app) resulting from the Automator application that you may want to “export” giving the name you’ve chosen.
    You can have this job done both via “new workflow” and via “new application” in Automator. Obviously saving this new application as an “app” in the launchpad, you’ll have this app everytime you need it.
    For they which do not know, Automator is an “application builder” like to put many macros together in a way that a certain result will be given.

  3. The plug in crashes every time I try to run it. I followed all instructions; placing the script in the right location and changing the default.env to contain the path to the convert.exe. I get a pythonw.exe has stopped working. Then I get a Plug-in crashed: “export-layers-to-pdf.py” and a GIMP Message Unable to run GimpPDBProgress callback. Any help would be much appreciated!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s