A previous article talked about PDFs received from an online source and how parts of the production process could be automated. Some items that are not so easy to automatically fix can have automation assist to reduce the manual work. Adjusting bleed and page size in a PDF is one example.
Page boxes determine what we are sizing and how they fit together. The Page boxes are named: Media, Crop, Art, Trim and Bleed.
To increase the size of the page, we adjust the Media box by 9 points all the way around. So the Media box will be adjusted as follows from the bottom left corner: [left -9, top 9, right 9, bottom -9]. This will make the PDF image centered in a 3.75 × 2.25 PDF page. The value of the new Media box will be [0, 162, 270, 0] and all new settings will be based on this value. The Trim box will then be set to [9, 144, 252, 9] and the Crop box and Bleed box will be set to match the Media box.