That's really what Uniscribe does, and explains a lot of pecularities of
Halant,ZWNJ before the base.
Sent Telugu from 1% failures to 0.03%. Improved Kannada and Malayalam
slightly. Fixed half of Bengali, and did NOT break anything!
matra_group = z*.M.N?.(H | forced_rakar)?;
syllable_tail = SM? (Coeng (cn|V))? (VD VD?)?;
place_holder = NBSP | DOTTEDCIRCLE;
-halant_group = (z?.h.z?);
-halant_or_matra_group = (halant_group | matra_group*);
+halant_group = (z?.h.ZWJ?);
+final_halant_group = halant_group | h.ZWNJ;
+halant_or_matra_group = (final_halant_group | matra_group*);
consonant_syllable = Repha? (cn.halant_group)* cn A? halant_or_matra_group? syllable_tail;
}
else
{
- /* A ZWJ at the end of syllable, or any ZWJ/ZWNJ in other places, stop the base
- * search (to request explicit half or halant forms. */
- if (is_joiner (info[i]) && (i + 1 < end || info[i].indic_category() == OT_ZWJ))
+ /* A ZWJ stops the base search, and requests an explicit half form. */
+ if (info[i].indic_category() == OT_ZWJ)
break;
}
} while (i > limit);