PDF page boxes
There are 5 page boxes in a PDF file:
- Mediabox
- Trimbox
- Bleedbox
- Cropbox
- Artbox
These different boxes are used to precisely define the content of your PDF file. They may or may not be present in your PDF file, depending on the software and method you used to create your PDF.
The mediabox is the largest box and (normally) contains all the objects of your document. The trimbox corresponds to your finished format and the bleedbox corresponds to the area that contains the objects that will be printed in excess of the finished format (and therefore being deleted during processing) – this area is very important, it allows a perfect printing finishing. For your file to be properly created (and this will be one of the mandatory criteria for the file to comply with the PDF/X standard), your trimbox must be contained in your bleedbox, which must itself be contained in the mediabox.
The cropbox is the part of the document you see when you open your file. It usually corresponds either to the trimbox (to display the finished format) or to the mediabox (to display everything). The artbox is very rarely used, it normally corresponds to the area surrounding objects within a page (without the “white” and is therefore smaller than the trimbox). Few applications generate this area (Adobe Illustrator does) and it is rarely used or even restricted (PDF/X for example).
Modify page boxes
PitStop offers many ways to modify page boxes, but it is quite complex to resize boxes in some cases. Indeed, if you want to enlarge a page box while keeping its position (so centered on its middle), it is only possible if you make calculations to obtain what value to add around the box, not very easy…
For example*, to move from a 215.9mm x 279.4mm area (Letter size) to 210mm x 297mm (A4 size), it will be necessary to calculate the horizontally left and right addition (210-215.9)/2 and the vertically top and bottom addition (297-279.4)/2. Ouch!
*(in real use case, we will rather have similar dimensions, such as going from 209.9 x 297.1 to 210 x 297 but this will make the example below more visible)

But why all these calculations? All you had to do was to use “Resize trimbox” and use “Define new rectangle” with the new dimensions!
Yes! …but NO 🙁
With this feature, it is necessary to give the coordinates of the lower left and upper right corner of the zone, in relation to the mediabox, in other words new and even more complex calculations!

Let’s make the artbox useful!
It is precisely because the artbox is not useful that we will use it!
The idea here is to use the artbox as a pivot area, which we will be able to create to the right size, then position it centrally on the existing trimbox (using the “Move Page Box” function) and finally use this new area correctly positioned and at the right size to create our new trimbox!

An example to download
To illustrate this, we have created a script that allows you to modify the trimbox according to the new dimensions you choose. While you’re at it, you will also be able to choose the size of the bleed!
This script uses a variable set so that you can enter any values. Remember to activate it before launching the script (the archive contains the script and the variable set in French and English)!
This was only one example, but you can apply the same principle for many other actions for positioning and resizing page boxes.
You don’t like using the artbox because it is useful to you or you don’t want to touch it?
You can also use a rectangle that you create in combination with either a very specific color, a spot color, or a layer. We will explain all this in detail in a future edition of Tech Mondays dedicated to PitStop tips and tricks.
Feel free to post your comments below!