Repository navigation
Paper
huzpsb edited this page Nov 8, 2026
·
2 revisions
Print the list of supported paper sizes — the reference for every -u, formsize:, dim: and papersize option in this wiki.
hspdf paperOutput includes ISO A/B/C series, US (Letter, Legal, Ledger, Tabloid, Statement, Executive), arch series and more.
Many commands take a form size, optionally with orientation enforced:
| Syntax | Meaning |
|---|---|
A4, Letter, …
|
as-is (natural orientation) |
A3L, LetterL
|
landscape enforced |
A4P, TabloidP
|
portrait enforced |
hspdf nup 'form:A3L' out.pdf 4 in.pdf
hspdf import 'f:Letter, pos:c' out.pdf photo.jpg
hspdf resize 'form:A4' in.pdf out.pdfAlternative to named sizes: explicit dim: <width> <height> in the chosen display unit (points by default, see -u).
There is no dedicated paper API — sizes are parsed as part of each command's description string (e.g. api.PDFNUpConfig, api.Import). A helper exists for page-insertion configuration:
// see pkg/pdfcpu for PageConfiguration details
conf := pdfcpu.DefaultPageConfig() // A4 portrait defaultshspdf wiki
Getting started
Fork features
Inspect
Document
Pages
Content
Extract
Resources
Security
Viewer
Trust
Developers