►V Reference

57.3 Text and Formulas🔗ℹ

A plain-text Visual stores one line of Unicode text together with font, color, alignment, transform, and opacity data. The string is copied into immutable model storage. Plain-text model values do not contain a Pict, font% object, drawing context, or platform font handle.

A formula Visual stores a LaTeX mathematical snippet together with its display mode, semantic font size, preamble, ordered typesetting options, alignment, transform, and opacity. Formula source and option strings are also copied into immutable model storage. A formula model value does not contain a Pict, PDF page, Poppler value, cached TeX result, or running process.

Font and formula sizes are measured in local world units. Horizontal and vertical alignment select the point of the untransformed text or formula box that lies at the Visual’s reference position. Alignment is resolved first; scale and rotation are then applied around that anchor. Both kinds of Visual can be top-level scene values or ordinary affine children of a group.

Plain text supports one line only. Carriage returns and newline characters are rejected. Formula source may contain line breaks because they can be meaningful to LaTeX. An empty plain-text or formula string is valid and produces stable transparent local geometry.

Formula rendering is a separate adapter effect. A nonempty formula requires latex-pict, LaTeX, and Poppler when it is converted to a Pict.

A formula assembly stores explicitly named formula parts in back-to-front order. An ordinary assembly uses independently typeset formula Visuals at caller-selected local positions. A tagged formula instead typesets all author-declared fragments in one TeX document and records each fragment as an SVG group at its TeX-determined local position. A formula correspondence records an explicit one-to-one list of source and destination-part names. The transform-formula-parts request compiles it against the current source assembly and produces deterministic moving and fading layers.