Skip to content
On this page

API Reference

Visual elements

Text - supports drawing text of different styles.

Image - draws an image with a known or dynamic size.

Background - applies solid background color beneath its children.

Border - applies solid border around its children.

Line - draws vertical or horizontal line.

Canvas - allows to extend standard set of visual elements by giving access to low-level SkiaSharp API.

Placeholder - draws simple placeholder image for prototyping purposes.

Positional elements

Width - sets minimum and/or maximum width constraint to its children.

Height - sets minimum and/or maximum height constraint to its children.

Alignment - allows to specify exact position of its child, e.g. in the middle, or in the low-bottom corner.

Padding - applies empty space around its children.

Aspect Ratio - reserves an area of provided aspect ratio.

Extend - extends child size to fit entire content vertically and/or horizontally.

Minimal box - minimizes child size to the smallest possible, useful when the parent element provides more space than necessary.

Translate - virtually moves the child horizontally and/or vertically in spaces.

Rotate - rotates its child.

Scale - scales its child to make it bigger or smaller.

Scale to fit - scales its child to fit available space.

Flip - rotates its child in 90 degrees increments.

Unconstrained - removes any size constraints, giving its child unlimited space.

Content flow elements

Page break - forces all following content to be moves to the next page.

Show if - conditionally displays its children.

Show once - displays its children only once, on the first page of occurrence. The element is not visible on subsequent pages.

Skip once - hides its children on the first page of occurrence. The element is visible on all subsequent pages.

Show entire - makes sure that the element is fully visible on a single page, without page breaking.

Ensure space - a less-strict version of the ShowEntire element. If the is not enough space to display entire element on a single page, it makes sure that the first page of occurrence has a minimal provided size. Used to visually optimize the layout.

Stop paging - displays its element on the first page only. If some part of the element does not fit, it is ignored.

Layout elements

Page - allows to manage page settings, e.g. size, margin, color, watermark, etc.

Table - arranges its children using table-layout algorithm. Supports row and column spanning.

Column - puts its children vertically, one under another.

Row - puts its children horizontally, one alongside another.

Grid - arranges its children using grid-layout algorithm. Available space is divided into set of equally spaced columns. Its child can take any number of columns.

Inlined - draws its elements in a line, supports various element alignments.

Decoration - puts additional content before and/or after its children. That additional content is repeated on all pages.

Layers - puts additional content underneath and/or above its children. The additional content is repeated on all pages. Useful when implementing watermarks.

List - draws its children as ordered or unordered list.

Other elements

Section - specifies a multi-page area spanning its children. Used to create internal document links and for showing custom page numbers.

Section Link - creates a link to provided section. Redirects the user to the first page of section occurrence.

Hyperlink - creates a link to external location, e.g. redirects the user to a webpage.

Element - allows you to break the Fluent API chain and inject dynamic content using lambda method.

Default Text Style - applies additional text styling for all text elements inside its hierarchy.

Debug Area - draws a colorful box with a label around its children. Useful for designing purposes.

Debug Pointer - marks its children with a special label. That label is useful to better understand document structure when the library throws layout-related exceptions.

Released under the MIT License.