From 59374f737079472aa5694b69ebced8c4cd5f9dfc Mon Sep 17 00:00:00 2001 From: Eric Biedert Date: Sat, 6 Jul 2024 15:45:19 +0200 Subject: Avoid spaces around ignorant and invisible elements in math (#4348) --- tests/ref/math-spacing-ignorant.png | Bin 0 -> 686 bytes tests/suite/math/spacing.typ | 10 ++++++++++ 2 files changed, 10 insertions(+) create mode 100644 tests/ref/math-spacing-ignorant.png (limited to 'tests') diff --git a/tests/ref/math-spacing-ignorant.png b/tests/ref/math-spacing-ignorant.png new file mode 100644 index 00000000..6fead62e Binary files /dev/null and b/tests/ref/math-spacing-ignorant.png differ diff --git a/tests/suite/math/spacing.typ b/tests/suite/math/spacing.typ index 2a387f92..707c09bb 100644 --- a/tests/suite/math/spacing.typ +++ b/tests/suite/math/spacing.typ @@ -49,6 +49,16 @@ $integral f(x) thin dif x$, // Both are weak, collide $integral f(x) #h(0.166em, weak: true)dif x$ +--- math-spacing-ignorant --- +// Test spacing with ignorant elements +$#metadata(none) "text"$ \ +$#place(dx: 5em)[Placed] "text"$ \ +// Operator spacing +$#counter("test").update(3) + b$ \ +$#place(dx: 5em)[a] + b$ +// Validate that ignorant elements are layouted +#context test(counter("test").get(), (3,)) + --- issue-1052-math-number-spacing --- // Test spacing after numbers in math. $ -- cgit v1.2.3