Overview
graphitepdf-document provides compatibility-oriented Document, Node, TextNode, and ImageNode types that can be lowered into the canonical GraphitePDF layout and render pipeline.
Scope
graphitepdf-document contains:
- compatibility
DocumentandNodeauthoring types - text and image node helpers for content modeling
- conversion into
graphitepdf_layout::Document,Page, andNode - compatibility with renderer sessions through
RendererDocumentSource
Installation
API Summary
| Category | Items |
|---|---|
| Document facade | Document, PdfMetadata |
| Nodes | Node, NodeKind, TextNode, ImageNode |
| Image compatibility | ImageSource |
| Pipeline integration | Document::to_layout_document() |
Example
use ;
Design Principles
- preserve compatibility-friendly document authoring shapes
- keep lowering into the canonical crates explicit
- avoid duplicating layout or rendering policy inside the facade
- make it easy to bridge user-facing APIs into the crate-native pipeline
Role In GraphitePDF
This crate sits above the canonical pipeline as an adapter layer. It is useful when callers want a simpler document facade, but the real work still flows through layout, render, renderer, and kit.
License
MIT