Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Making PDF
#1
I want to make a PDF with pages of different sizes and I add them as layers to the first page but Gimp crops the ones which are bigger than the first page. How can I do it then?
Reply
#2
I think I know want you want but not too sure. If you can paste a screenshot showing layers ?

Gimp will use the first (bottom) layer as a canvas size and subsequent layers only 'show' that size. Generally you need to open the largest layer first.

For an existing PDF where the layers (pages) are in order, make a new canvas large enough for all and then open the PDF Image -> Open as Layers

Want to add the different sizes to the (smaller) first layer. Several ways, scale the large layers down or scale the small layer up.
Reply
#3
(01-08-2022, 06:20 PM)rich2005 Wrote: I think I know want you want but not too sure.  If you can paste a screenshot showing layers ?

Gimp will use the first (bottom) layer as a canvas size and subsequent layers only 'show' that size.  Generally you need to open the largest layer first.

For an existing PDF where the layers (pages) are in order, make a new canvas large enough for all and then open the PDF Image -> Open as Layers

Want to add the different sizes to the (smaller) first layer. Several ways, scale the large layers down or scale the small layer up.

You got it right. The problem with choosing a larger canvas size is that the area around the smaller page becomes white
Reply
#4
I do see the problem exporting layers as a PDF, where white borders pad out to the image size.

I have an old gimp script that will do the job but with some restrictions. Each image (page) is open as a separate image (not as layers) and the printing resolution is the same for each image. Not a problem for a few images but not really practical if there are dozens.
...how many images are you using ?
Reply
#5
(01-09-2022, 09:23 PM)rich2005 Wrote: I do see the problem exporting layers as a PDF, where white borders pad out to the image size.

I have an old gimp script that will do the job but with some restrictions. Each image (page) is open as a separate image (not as layers) and the printing resolution is the same for each image. Not a problem for a few images but not really practical if there are dozens.
...how many images are you using ?

It's for only one job. I make pdf files quite often. They can have around 15 pages
Reply
#6
Some ways for that borderless paged pdf. The old script  sg-save-pdf-multi-210.scm in the attached  zip (with another script for exporting layers-to-images if needed) these go in your user scripts folder.

The problem with the script is you need to have each image individually open, a multi-layer is no good.  15 images / pages, just about manageable, more than that - up to you.

However, to start off, open your images as layers, then Image -> Fit Canvas to Layers and that fixes any truncated layers, no scaling involved, no borders added and regularizes the dpi.   

Then either drag each layer  into the toolbox to open as a new image, or export all of them then re-open as individual images.

sg-save-pdf-multi-210.scm registers in File -> Create -> Export  Multi-page PDF  Add the open images in the required order.

I did look at using LibreOffice or Scribus but these do add the border you do not want.

Finally, an alternative, not Gimp, ImageMagick http://www.imagemagick.org can take a folder of jpg images and make a much smaller PDF than Gimp. Worth considering.

6 minutes demo https://youtu.be/wmbDoT7z-T0





Attached Files
.zip   pdf-multi.scm.zip (Size: 4.26 KB / Downloads: 89)
Reply
#7
(01-16-2022, 03:30 PM)rich2005 Wrote: Some ways for that borderless paged pdf. The old script  sg-save-pdf-multi-210.scm in the attached  zip (with another script for exporting layers-to-images if needed) these go in your user scripts folder.

The problem with the script is you need to have each image individually open, a multi-layer is no good.  15 images / pages, just about manageable, more than that - up to you.

However, to start off, open your images as layers, then Image -> Fit Canvas to Layers and that fixes any truncated layers, no scaling involved, no borders added and regularizes the dpi.   

Then either drag each layer  into the toolbox to open as a new image, or export all of them then re-open as individual images.

sg-save-pdf-multi-210.scm registers in File -> Create -> Export  Multi-page PDF  Add the open images in the required order.

I did look at using LibreOffice or Scribus but these do add the border you do not want.

Finally, an alternative, not Gimp, ImageMagick http://www.imagemagick.org can take a folder of jpg images and make a much smaller PDF than Gimp. Worth considering.

6 minutes demo https://youtu.be/wmbDoT7z-T0



Great! Thank you very much! I suppose the script will work on newer versions too, right? and no matter we're using it in Windows or Linux? It lacks some features especially for reducing the quality and size but it's very good that there is such option.
Reply
#8
(02-14-2022, 09:06 AM)Al- Wrote: Great! Thank you very much! I suppose the script will work on newer versions too, right? and no matter we're using it in Windows or Linux? It lacks some features especially for reducing the quality and size but it's very good that there is such option.

It works with Gimp 2.10 as the demo, but remember it is a Gimp 2.8 script that reinstates a function from even earlier versions of Gimp. AFAIK ok for linux or Windows

Up to you to maintain consistent quality and ppi values over the images. This is a Gimp forum so that is a Gimp solution.

However Gimp makes monster size PDF files due to the compression used for PDF's. If you want smaller more efficient PDF's then look at using ImageMagick especially for linux.
Reply
#9
(02-14-2022, 09:31 AM)rich2005 Wrote:
(02-14-2022, 09:06 AM)Al- Wrote: Great! Thank you very much! I suppose the script will work on newer versions too, right? and no matter we're using it in Windows or Linux? It lacks some features especially for reducing the quality and size but it's very good that there is such option.

It works with Gimp 2.10 as the demo, but remember it is a Gimp 2.8 script that reinstates a function from even earlier versions of Gimp. AFAIK ok for linux or Windows

Up to you to maintain consistent quality and ppi values over the images.  This is a Gimp forum so that is a Gimp solution.

However Gimp makes monster size PDF files due to the compression used for PDF's. If you want smaller more efficient PDF's then look at using ImageMagick especially for linux.
Thanks a lot! I'll check it, though I think this script will do what I need. I got one step closer to use Gimp instead of Photoshop
Reply


Forum Jump: