Tex
Tex typesets math in a Box. It uses RaTeX
and supports KaTeX syntax.
Use a literal markup body for multiline math. In Ebi strings, prefix the string
with r to preserve braces and write two backslashes for each LaTeX backslash,
as in Tex(r"\\sum_{i=1}^n i"). Ebi uses display style by default.
Single dollar signs or \(…\) select inline style. Use display=false to set
inline style explicitly. font_size sets the math size, color sets the formula's
ink, and fill sets the Box background. Box options such as padding and alignment
apply to the whole formula.
Set font to "math" (the default), "serif", "sans-serif", or "monospace".
font_weight selects the closest bundled weight, with 400 for regular and
700 for bold. These settings apply to unstyled math glyphs. Uncovered symbols
use their standard math face, and the bundled monospace face has one weight.
Use commands such as \mathcal{F} and \mathbb{R} to style individual symbols.
Use .select(part=...) to highlight a math fragment and .select() to clear
the highlight. Give .edit(...) a new formula to replace all of it, or add
part= to replace one fragment. occurrence=2 targets the second matching
fragment in source order. Select a complete fragment, such as x^2, \alpha,
or \frac{1}{2}. Edits keep unchanged fragments together as the equation
reflows. Delimiters resize with the formula, and replacement ink fades in after
the old ink fades out. An edit clears the selection.