pageSize gives the width and the height of a standard page in millimetres. The other functions find formats and make the frame of a sheet.
Import
Example
Notes
- Landscape exchanges the width and the height.
- For a custom size, write the width and the height in the sheet.
sizeMatchesFormatchecks that a size agrees with its format.
pageSize
Resolve a named format + orientation to width/height in millimetres.formatsIn
Formats in a family, largest first — the order a size picker lists them.sizeMatchesFormat
Whether a stored size agrees with the format and orientation it claims.sheetFrameFor
Resolve a page to its frame.sheetFrameGeometry
The frame as drawable geometry, in absolute paper millimetres.PAGE_SPECS
Portrait dimensions in millimetres for each named format.PAGE_FAMILY
The standard each format belongs to.Types
PageFormat
Standard page sizes for paper space, in millimetres (portrait, width × height), with a top-left origin (x increases right, y increases down).PageOrientation
PageSize type
PageFamily
Which standard a format belongs to — what a size picker groups by.SheetFrame
What a sheet’s frame looks like, resolved to absolute paper millimetres.SheetMargins
required
FrameRect
required
The rect the frame is stroked on, and that the title block anchors to.
boolean
required
boolean
required
SheetZones
SheetMargins
Inset from each page edge, in paper millimetres.FrameRect
Rectangle in paper millimetres. The package does not export this type by name.SheetZones
The zone reference grid along the border — how a drawing says “see B4”.number
required
number
required
number
required
Depth of the labelled band, measured inwards from the page edge.