[Indic] Don't form Reph is Ra is the only consonant in the syllable

This commit is contained in:
Behdad Esfahbod 2012-05-10 11:37:42 +02:00
parent b99d63ae11
commit 3d25079f8d
2 changed files with 11 additions and 1 deletions

View File

@ -63,7 +63,7 @@ enum indic_category_t {
/* Visual positions in a syllable from left to right. */
enum indic_position_t {
POS_RA,
POS_RA_TO_BECOME_REPH,
POS_LEFT_MATRA,
POS_PRE_C,

View File

@ -287,6 +287,16 @@ initial_reordering_consonant_syllable (const hb_ot_map_t *map, hb_buffer_t *buff
if (base < start)
base = start; /* Just in case... */
/* -> If the syllable starts with Ra + Halant (in a script that has Reph)
* and has more than one consonant, Ra is excluded from candidates for
* base consonants. */
if (has_reph && base == start) {
/* Have no other consonant, so Reph is not formed and Ra becomes base. */
has_reph = false;
}
/* 2. Decompose and reorder Matras:
*