PageSpec

data class PageSpec(val size: PageSize, val padding: Padding, val content: ColumnNode, val pageBreakStrategy: PageBreakStrategy, val header: (PageContext) -> ColumnNode? = null, val footer: (PageContext) -> ColumnNode? = null, val watermark: BoxNode? = null)

One logical page in the source DSL. May expand into multiple physical PDF pages at render time when content overflows.

Constructors

Link copied to clipboard
constructor(size: PageSize, padding: Padding, content: ColumnNode, pageBreakStrategy: PageBreakStrategy, header: (PageContext) -> ColumnNode? = null, footer: (PageContext) -> ColumnNode? = null, watermark: BoxNode? = null)

Properties

Link copied to clipboard
Link copied to clipboard
val footer: (PageContext) -> ColumnNode? = null

same as header but rendered at the bottom of every physical page.

Link copied to clipboard
val header: (PageContext) -> ColumnNode? = null

optional builder invoked once per physical page; the resulting ColumnNode is rendered above the body content and excluded from the body's content area. Pure of side effects — the renderer may invoke it more than once.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val watermark: BoxNode? = null

optional BoxNode drawn behind every physical page's body content. Spans the full page area (not the content frame) so corner-anchored watermarks land in the page padding band rather than the content gutter.