Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

gallery

A visual gallery of the published examples: each example shown three ways — the graph source, the CLI’s ASCII render (the byte-verified expected.txt), and an SVG rendering.

How the SVG is produced

Upstream Graph::Easy v0.69 ships no SVG module, so SVG is out of scope for gently’s v1 renderers. What you see here instead is gently’s own library Graphviz renderer (gently_core::render::graphviz, spec-pinned ge.graphviz_render) emitting DOT source, piped through dot -Tsvg:

examples/<name>/input.gv → text parser → graphviz render (DOT) → dot -Tsvg → docs/gallery/<name>.svg

The committed SVGs are drift-gated: just gallery-verify regenerates every SVG through exactly this path and fails on any byte mismatch — the same culture as just examples-verify for the ASCII output.


diamond

Input:

[ a ] --> [ b ]
[ a ] --> [ c ]
[ b ] --> [ d ]
[ c ] --> [ d ]

CLI ASCII render:

+---+     +---+     +---+
| a | --> | b | --> | d |
+---+     +---+     +---+
  |                   ^
  |                   |
  v                   |
+---+                 |
| c | ----------------+
+---+

SVG:

edge-attributes

Input:

[ AB ] --> { style: bold; label: foo; } [ ABC ]

CLI ASCII render:

+----+  foo   +-----+
| AB | #####> | ABC |
+----+        +-----+

SVG:

edge-styles

Input:

[ Bonn ] -- solid --> [ Berlin ]
[ Berlin ] == double ==> [ Rostock ]

CLI ASCII render:

+------+  solid   +--------+  double   +---------+
| Bonn | -------> | Berlin | ========> | Rostock |
+------+          +--------+           +---------+

SVG:

isolated-node

Input:

[ a ] --> [ b ]
[ d ]
[ b ] --> [ c ]

CLI ASCII render:

+---+     +---+     +---+
| a | --> | b | --> | c |
+---+     +---+     +---+
+---+
| d |
+---+

SVG:

parallel-edges

Input:

[ a ] --> [ b ]
[ a ] --> [ b ]

CLI ASCII render:


  +---------+
  |         v
+---+     +---+
| a | --> | b |
+---+     +---+

SVG:

self-loop

Input:

[ a ] --> [ a ]

CLI ASCII render:


  +--+
  v  |
+------+
|  a   |
+------+

SVG:

simple-chain

Input:

[ a ] --> [ b ]
[ b ] --> [ c ]

CLI ASCII render:

+---+     +---+     +---+
| a | --> | b | --> | c |
+---+     +---+     +---+

SVG:


Where the truth lives

The ASCII renders above are the committed, byte-verified examples/<name>/expected.txt files, kept honest by just examples-verify; known gaps are tracked in docs/known-hard-cases.md.