From e848bfae7c975a6fae434daf8e3db4d69914df9f Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Thu, 22 May 2014 18:50:34 -0400 Subject: [PATCH] [indic] Recategorize U+A8E0..A8F1 as OT_VD Up to two of them come after all OT_A characters. --- src/hb-ot-shape-complex-indic-machine.rl | 2 +- src/hb-ot-shape-complex-indic.cc | 10 ++++++---- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/hb-ot-shape-complex-indic-machine.rl b/src/hb-ot-shape-complex-indic-machine.rl index 05f62f2c..5e288435 100644 --- a/src/hb-ot-shape-complex-indic-machine.rl +++ b/src/hb-ot-shape-complex-indic-machine.rl @@ -69,7 +69,7 @@ cn = c.ZWJ?.n?; forced_rakar = ZWJ H ZWJ Ra; avagraha = Avag.N?; matra_group = z{0,3}.M.N?.(H | forced_rakar)?; -syllable_tail2 = (SM.SM?.ZWNJ?)? A{0,3}? VD?; +syllable_tail2 = (SM.SM?.ZWNJ?)? A{0,3}? VD{0,2}; syllable_tail = (Coeng (cn|V))? avagraha? syllable_tail2; place_holder = NBSP | DOTTEDCIRCLE; halant_group = (z?.h.(ZWJ.N?)?); diff --git a/src/hb-ot-shape-complex-indic.cc b/src/hb-ot-shape-complex-indic.cc index 01d6d965..f11e7f37 100644 --- a/src/hb-ot-shape-complex-indic.cc +++ b/src/hb-ot-shape-complex-indic.cc @@ -198,14 +198,16 @@ set_indic_properties (hb_glyph_info_t &info) * U+092E,U+0952,U+0951 */ if (unlikely (hb_in_ranges (u, 0x0951, 0x0952, - 0xA8E0, 0xA8F1) && - hb_in_ranges (u, 0x1CD0, 0x1CD2, - 0x1CD4, 0x1CE0, - 0x1CF4, 0x1CF4))) + 0x1CD0, 0x1CD2, + 0x1CD4, 0x1CE0) || + u == 0x1CF4)) cat = OT_A; /* The following act more like the Bindus. */ else if (unlikely (hb_in_range (u, 0x0953, 0x0954))) cat = OT_SM; + /* Cantillation marks. */ + else if (unlikely (hb_in_range (u, 0xA8E0, 0xA8F1))) + cat = OT_VD; if (unlikely (u == 0x17D1)) cat = OT_X; -- GitLab