summaryrefslogtreecommitdiff
path: root/tests/typ/bugs
diff options
context:
space:
mode:
authorbluebear94 <uruwi@protonmail.com>2023-06-26 07:40:21 -0400
committerGitHub <noreply@github.com>2023-06-26 13:40:21 +0200
commit9ef4643ba104acc08cd3a4fce8cfea72253654b1 (patch)
tree62d5e2a87de702187825094eb98b4a391874c83a /tests/typ/bugs
parent47a131dfbb9cf3c0adad6e0d9d669f750fbda658 (diff)
shape_tofus: respect text direction when inserting tofus (#1519)
This ensures that the ranges of the shaped glyphs are monotonically decreasing in right-to-left-text, thus avoiding nonsensical results in find_safe_to_break that later causes a panic (see #1373). Additionally, debug assertions have been added to catch non-monotonic glyph ranges.
Diffstat (limited to 'tests/typ/bugs')
-rw-r--r--tests/typ/bugs/bidi-tofus.typ7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/typ/bugs/bidi-tofus.typ b/tests/typ/bugs/bidi-tofus.typ
new file mode 100644
index 00000000..3b43b280
--- /dev/null
+++ b/tests/typ/bugs/bidi-tofus.typ
@@ -0,0 +1,7 @@
+// Test that shaping missing characters in both left-to-right and
+// right-to-left directions does not cause a crash.
+
+---
+#"\u{590}\u{591}\u{592}\u{593}"
+
+#"\u{30000}\u{30001}\u{30002}\u{30003}"