Expand description
Deterministic SVG serializer for KiCad Plotter-IR documents.
Renders typed KiCad footprint, symbol, board, and schematic-page Plotter-IR documents directly into reproducible SVG with validated styling, layer filtering, viewport fitting, and source-identity preservation.
Structs§
- SvgArtifact
- Rendered SVG document together with resolved viewport, bounds, and telemetry.
- SvgBounds
- Axis-aligned bounding box of visible rendered geometry in nanometres.
- SvgColor
- Validated canonical uppercase
#RRGGBBor#RRGGBBAAsRGB hex color. - SvgError
- Structured error returned by SVG context validation or rendering.
- SvgFit
Options - Parameters controlling
ViewportPolicy::Fitautomatic viewport sizing. - SvgMetrics
- Deterministic work and size counters reported on every
SvgArtifact. - SvgRender
Context A1 - Unvalidated SVG presentation policy; call
SvgRenderContextA1::validatebefore rendering. - SvgRender
Context Builder - Fluent builder for constructing an
SvgRenderContextA1. - SvgStyle
Override - Partial style override merged in precedence order during SVG emission.
- SvgViewport
- Explicit SVG
viewBoxrectangle in integer nanometres. - SvgVisibility
- Visibility toggles for schematic symbol pin annotations.
- Validated
SvgRender Context A1 - Validated, immutable SVG render context shared across direct typed renderers.
Enums§
- Layer
Pattern - Case-sensitive KiCad layer selector (
*, exact name,*.Suffix, or<unlayered>). - Layer
Selection - Layer inclusion filter applied to PCB and footprint SVG renders.
- Plotter
Operation Kind - Plotter-IR drawing operation kind addressable by style overrides.
- SvgBackground
- Canvas background fill policy for an emitted SVG document.
- SvgError
Kind - Machine-readable category for an
SvgError. - SvgFill
Mode - Shape fill override policy.
- SvgIdentity
Mode - Controls whether source UUID/object identity attributes are emitted on SVG elements.
- SvgLine
Style - Stroke dash-pattern override policy.
- SvgPrimitive
Class - Source-owned primitive categories; shape alone does not identify a pad’s role.
- SvgProfile
- SVG rendering profile governing element structure and styling semantics.
- SvgSemantic
Role - High-level CAD semantic role used to apply theme-level style overrides.
- SvgWarning
- Non-fatal diagnostic warning attached to an
SvgArtifact. - Viewport
Policy - Policy selecting either an explicit
viewBoxor automatic fit-to-content framing.
Functions§
- render_
board_ document_ svg - Render a standalone typed PCB Plotter-IR document with all layers visible.
- render_
board_ svg - Render a projected PCB Plotter-IR artifact with full copper-stack layer filtering.
- render_
footprint_ svg - Render a validated KiCad footprint Plotter-IR document directly to SVG.
- render_
schematic_ page_ svg - Render a projected hierarchical schematic page artifact with occurrence identity preserved.
- render_
schematic_ svg - Render a standalone typed schematic Plotter-IR document directly to SVG.
- render_
symbol_ svg - Render a validated KiCad symbol Plotter-IR document directly to SVG.