Expand description
The imperative painting surface. A Canvas accumulates
pdfboss_core::content::Op values — the exact IR the reader parses —
plus the fonts and images those operators reference. Nothing here
serializes; finish hands the parts to document assembly.
Resource naming contract: the font first used gets resource name F1,
the next distinct font F2, …; image handles map to Im1, Im2, … in
add_image order; groups registered with
group map to Gp1, Gp2, …; distinct /ExtGState
entries pushed by the alpha/blend-mode setters map to Gs1, Gs2, ….
Assembly builds the matching /Resources dictionary from
CanvasParts.
Structs§
- Canvas
- An imperative painter producing content-stream operators.
- Canvas
Parts - The accumulated output of a finished canvas.
- Group
Handle - Handle to a sub-canvas registered with
Canvas::group, painted withCanvas::draw_group. - Image
Handle - Handle to an image registered on a canvas.
Enums§
- Blend
Mode - A separable blend mode (ISO 32000 §11.3.5, Table 136), set with
Canvas::set_blend_mode. - LineCap
- Line cap style (ISO 32000 §8.4.3.3).
- Line
Join - Line join style (ISO 32000 §8.4.3.4).