Expand description
The TikZ/pgf statement unit model: which gaps inside a picture-body
STATEMENT are unit-internal and must never become width-break
opportunities.
The parser’s STATEMENT node owns a statement’s extent (everything up to
the top-level ;), which is all the boundary layout and the continuation
hang need. What extent cannot give is good breaks inside a statement: the
interior is an undifferentiated atom stream, so a width fill would happily
break a coordinate from its operation (\draw (6,6) / circle (3);) or an
at from its coordinate. These are vocabulary-dependent relationships, so
they belong in the semantic layer rather than the grammar. A missed or
incorrect relationship can affect line breaking, but never the syntax tree.
The model is deliberately a glue map, not a grammar: for each authored gap between a statement’s top-level elements, one verdict — unit-internal (render as a single space, never break) or neutral (an ordinary break opportunity). Everything unrecognized is neutral. All reads are non-trivia token text, so the verdicts are Tier 1 by construction: no trivia predicate is consulted, and a width wrap re-derives the same units on every pass.
Functions§
- statement_
glue - Per-element glue verdicts for a
STATEMENT’s top-level element stream.