Documentation overview

Untie Documentation

Untie parses TeX or Typst math into one language-neutral IR and lays that IR out with a host-supplied OpenType MATH font. The result is a UI-independent display list of filled…

These docs describe the public API at library version 0.2.1 and layout revision 1. They focus on the behavior a host or code assistant can rely on when integrating Untie; they are not a TeX or Typst language tutorial.

Start Here

  • Getting started shows the complete LoadMathFont -> NewRenderer -> Render -> draw flow, with the lower-level engine path documented separately.
  • Core concepts and ownership explains the pipeline, the lifetime of each value, and the inline/display boundary.
  • Rendering the display list defines coordinates, items, lines, tags, hits, overflow, bounds, drawing helpers, and optional SVG/PNG output.

Integration Guides

Compatibility and Verification

  • Supported TeX summarizes the tested TeX math subset and its explicit exclusions.
  • Supported Typst summarizes the restricted Typst math frontend and its explicit exclusions.
  • API stability tiers separates the host API, advanced IR types, and diagnostic serialization.
  • Release process records versioning, module tags, and the automated GitHub release gate.
  • Security policy explains supported versions and private vulnerability reporting.
  • Compatibility and verification summarizes the tracked corpora and reviewed coverage.
  • Performance explains the benchmark workload, cache strategies, and allocation metrics.
  • Migrating to 0.2 maps the removed low-level font and drawing conveniences to the current host facade, render helpers, and output adapters.
  • encode/svg emits deterministic standalone SVG through the same framework-neutral drawing protocol.
  • encode/raster renders a display box to a deterministic antialiased RGBA image or PNG without cgo or a UI dependency.

For a normal application:

  1. Getting started
  2. Rendering the display list
  3. Fonts and fallback
  4. Errors and resource limits

For an editor or document application:

  1. Parsing, diagnostics, and recovery
  2. Concurrency, lifecycle, and caching
  3. Accessibility text
  4. The supported-syntax page for the active input dialect

For a host that stores or transforms formula trees:

  1. Canonical IR
  2. API stability tiers
  3. Compatibility and verification
  4. Performance

Scope

Untie does not provide a document engine, font discovery, system keyboard layout, DOM, network access, or semantic TeX/Typst execution. The host owns those concerns. Untie's contract ends at a validated Box, its accessibility text, and its source metadata.

The bundled examples/mygo application demonstrates direct formula elements in a native editor.

For MyGo integration, use contrib/mygo. It can render a formula directly as a ui.Element, bind Markdown math, or draw an existing Untie box.