typst/tests/typ/math/content.typ
Leedehai 62361b4127
Support indices preceding the base symbol, revamping #699 (#825)
Breaking change: abbreviate attach() attachment params, top -> t, bottom -> b
2023-04-25 11:24:07 +02:00

20 lines
460 B
Typst

// Test arbitrary content in math.
---
// Test images and font fallback.
#let monkey = move(dy: 0.2em, image("/monkey.svg", height: 1em))
$ sum_(i=#emoji.apple)^#emoji.apple.red i + monkey/2 $
---
// Test tables.
$ x := #table(columns: 2)[x][y]/mat(1, 2, 3)
= #table[A][B][C] $
---
// Test non-equation math directly in content.
#math.attach($a$, t: [b])
---
// Test font switch.
#let here = text.with(font: "Noto Sans")
$#here[f] := #here[Hi there]$.