mirror of
https://github.com/storytold/figcraft.git
synced 2026-10-24 10:27:00 -06:00
M4: right-to-left and mixed-direction text (Unicode bidi) (#34)
Text runs get bidi embedding levels from the Unicode bidi algorithm (unicode-bidi, MIT/Apache-2.0). Right-to-left runs are shaped right to left, kept in logical order for line breaking and placed in visual order per line (rule L2, trailing spaces at the paragraph level). Glyphs and lines know their direction, so the caret, clicks and selection highlights follow right-to-left runs. Text without right-to-left characters skips the analysis. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -43,6 +43,7 @@ usvg = "0.48"
|
||||
krilla = "0.8"
|
||||
skrifa = "0.47"
|
||||
harfrust = "0.13"
|
||||
unicode-bidi = "0.3"
|
||||
linesweeper = "0.4"
|
||||
zip = { version = "2", default-features = false, features = ["deflate"] }
|
||||
sha2 = "0.10"
|
||||
|
||||
Reference in New Issue
Block a user