Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateFromIPM ¶
GenerateFromIPM generates SVG from IPM model by running layout internally. Convenience wrapper that composes layout generation with SVG rendering.
Types ¶
type Generator ¶
type Generator struct {
}
Generator produces minimal SVG previews from layout graphs.
Stub rendering is NOT an option: an edge whose Visibility the layout classified "stubbed" always renders as a numbered stub pair (short segment + fade + pair-number badge at each end, the full edge kept hidden as class "edge-full" for hover reveal). The flat SVG and the canvas agree on what is hidden — classify once, consume everywhere.
func NewGenerator ¶
NewGenerator creates a new SVG generator.
func (*Generator) Generate ¶
Generate returns a minimal SVG preview for a layout graph. Implements styling from gl:docs/dev/layout-gen/layout-alg.md (events, things, concepts sections)
func (*Generator) GenerateWithHints ¶
func (g *Generator) GenerateWithHints(graph *layout.Graph, hints nodehints.GraphHints) ([]byte, error)
GenerateWithHints is like Generate but overlays per-node decoration symbols from the provided hints map. Nodes absent from hints render normally. pkg/ipmsvg has no knowledge of what decorations mean — it only draws them.