From 5c558877da5db8c734ba072f01e5e4797876619c Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Wed, 16 Oct 2013 11:14:15 +0200 Subject: [PATCH] [indic] Allow up to two syllable modifiers Bug 70509 - Candrabindu+Visarga doesn't work in Devanagari https://bugs.freedesktop.org/show_bug.cgi?id=70509 We categorize both bindus and visarga as syllable-modifiers. OT spec doesn't actually say what characters go in the syllable modifier category, and allows one. We just allow up to two now. Test case: U+0930,U+0941,U+0901,U+0903 Uniscribe currently doesn't support that and produces a dotted circle. --- src/hb-ot-shape-complex-indic-machine.rl | 2 +- .../in-tree/shaper-indic/indic/script-devanagari/misc/misc.txt | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/hb-ot-shape-complex-indic-machine.rl b/src/hb-ot-shape-complex-indic-machine.rl index fa068c43..f0c66c45 100644 --- a/src/hb-ot-shape-complex-indic-machine.rl +++ b/src/hb-ot-shape-complex-indic-machine.rl @@ -67,7 +67,7 @@ reph = (Ra H | Repha); # possible reph cn = c.ZWJ?.n?; forced_rakar = ZWJ H ZWJ Ra; matra_group = z{0,3}.M.N?.(H | forced_rakar)?; -syllable_tail = (Coeng (cn|V))? (Avag.N?)? (SM.ZWNJ?)? (VD VD?)?; +syllable_tail = (Coeng (cn|V))? (Avag.N?)? (SM.SM?.ZWNJ?)? (VD.VD?)?; place_holder = NBSP | DOTTEDCIRCLE; halant_group = (z?.h.(ZWJ.N?)?); final_halant_group = halant_group | h.ZWNJ; diff --git a/test/shaping/texts/in-tree/shaper-indic/indic/script-devanagari/misc/misc.txt b/test/shaping/texts/in-tree/shaper-indic/indic/script-devanagari/misc/misc.txt index 80bc4a62..abf97602 100644 --- a/test/shaping/texts/in-tree/shaper-indic/indic/script-devanagari/misc/misc.txt +++ b/test/shaping/texts/in-tree/shaper-indic/indic/script-devanagari/misc/misc.txt @@ -31,3 +31,4 @@ र्आ्र् क‌ि ऽं +रुँः -- GitLab