[Indic] Position final subjoined consonants (and vowels) after matras
In Khmer, a final subjoined consonant or independent vowel can occur after matras. This final subjoined thing should NOT be reordered to before the matra even though it's subjoined. Fixes another 1k of the Khmer failures. Not much left really.
This commit is contained in:
parent
c50ed71e9a
commit
55f70ebfb9
|
@ -75,6 +75,7 @@ enum indic_position_t {
|
||||||
POS_BELOW_M,
|
POS_BELOW_M,
|
||||||
POS_POST_C,
|
POS_POST_C,
|
||||||
POS_POST_M,
|
POS_POST_M,
|
||||||
|
POS_FINAL_C,
|
||||||
POS_SMVD
|
POS_SMVD
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -429,8 +429,21 @@ initial_reordering_consonant_syllable (const hb_ot_map_t *map, hb_buffer_t *buff
|
||||||
|
|
||||||
for (unsigned int i = start; i < base; i++)
|
for (unsigned int i = start; i < base; i++)
|
||||||
info[i].indic_position() = POS_PRE_C;
|
info[i].indic_position() = POS_PRE_C;
|
||||||
|
|
||||||
info[base].indic_position() = POS_BASE_C;
|
info[base].indic_position() = POS_BASE_C;
|
||||||
|
|
||||||
|
/* Mark final consonants. A final consonant is one appearing after a matra,
|
||||||
|
* like in Khmer. */
|
||||||
|
for (unsigned int i = base + 1; i < end; i++)
|
||||||
|
if (info[i].indic_category() == OT_M) {
|
||||||
|
for (unsigned int j = i + 1; j < end; j++)
|
||||||
|
if (is_consonant (info[j])) {
|
||||||
|
info[j].indic_position() = POS_FINAL_C;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
/* Handle beginning Ra */
|
/* Handle beginning Ra */
|
||||||
if (has_reph)
|
if (has_reph)
|
||||||
info[start].indic_position() = POS_RA_TO_BECOME_REPH;
|
info[start].indic_position() = POS_RA_TO_BECOME_REPH;
|
||||||
|
|
|
@ -8,3 +8,5 @@
|
||||||
រ៍
|
រ៍
|
||||||
សៅ
|
សៅ
|
||||||
រ្ឥ
|
រ្ឥ
|
||||||
|
ងឹ្ឈ
|
||||||
|
ង្ឈឹ
|
||||||
|
|
Loading…
Reference in New Issue