Expand description
§Style System
A CSS-like style model for document nodes. This is intentionally a subset of CSS that covers the properties needed for document layout: flexbox, box model, typography, color, borders.
We don’t try to implement all of CSS. We implement the parts that matter for PDF documents, and we implement them correctly.
Structs§
- Color
- An RGBA color.
- Corner
Values - Values for each corner (top-left, top-right, bottom-right, bottom-left).
- Edge
Values - Values for each edge (top, right, bottom, left).
- Grid
Placement - Grid item placement.
- Resolved
Style - Resolved style: all values are concrete (no Option, no Auto for computed values). This is what the layout engine works with after style resolution.
- Style
- The complete set of style properties for a node.
Enums§
- Align
Content - Align
Items - Dimension
- A dimension that can be points, percentage, or auto.
- Direction
- Text direction for BiDi support.
- Display
- Layout display mode.
- Flex
Direction - Flex
Wrap - Font
Style - Grid
Track Size - A single grid track size definition.
- Hyphens
- CSS
hyphensproperty controlling word hyphenation. - Justify
Content - Line
Breaking - Line breaking algorithm.
- Overflow
- Overflow behavior for container elements.
- Size
Constraint - Text
Align - Text
Decoration - Text
Overflow - Text overflow behavior when text exceeds available width.
- Text
Transform