PDF Page Dimensions & Orientation
In a PDF, the physical dimensions of a page are defined by the /MediaBox dictionary, which specifies a bounding box in points (1/72 of an inch). This box can change dynamically from page to page within the same document.
These files test your parser's ability to adapt to varying /MediaBox coordinate planes. From standard A4 and US Letter sizes down to tiny 4x6 shipping labels, these documents ensure your print spoolers and web viewers accurately scale, rotate, and zoom the canvas.
4x6 Shipping Label
A custom small-format MediaBox mimicking standard thermal shipping labels. Essential for testing logistics and barcode-printing APIs.
Portrait
A document strictly adhering to a vertical (portrait) orientation across all pages.
Landscape
A document strictly adhering to a horizontal (landscape) orientation.
Letter
Standard US Letter dimensions (8.5" x 11"). The default fallback for most North American print parsers.
Legal
US Legal dimensions (8.5" x 14"). Useful for testing vertical scaling and continuous scrolling algorithms.
A4
ISO A4 dimensions (210mm x 297mm). The international standard, critical for testing global localization defaults.
A5
ISO A5 dimensions. Tests small-format rendering and aggressive responsive-UI text wrapping.
A3
ISO A3 dimensions. Tests large-format rendering and horizontal zoom constraints.
Mixed orientation
A complex file that alternates between Portrait and Landscape `/MediaBox` definitions mid-document. Crucial for testing layout engine adaptability.
Frequently Asked Questions
Use Cases
- Validating print-spooling algorithms to ensure they select the correct physical paper tray based on MediaBox dimensions.
- Testing thumbnail-generation tools to ensure landscape pages aren't squished or cropped when rendering a grid.
- Ensuring coordinate-based OCR pipelines don't extract text out-of-bounds when pages dynamically shrink or expand.