usp10: Refine Ralf reordering location for Devanagari and Gujarati.
This commit is contained in:
parent
81183c1e20
commit
3cc6129681
|
@ -1858,17 +1858,16 @@ static void Reorder_Ra_follows_base(LPWSTR pwChar, INT start, INT main, INT end,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void Reorder_Ra_follows_matra_post(LPWSTR pwChar, INT start, INT main, INT end, lexical_function lexical)
|
static void Reorder_Ra_follows_matra(LPWSTR pwChar, INT start, INT main, INT end, lexical_function lexical)
|
||||||
{
|
{
|
||||||
if (start != main && end > start+1 && lexical(pwChar[start]) == lex_Ra && lexical(pwChar[start+1]) == lex_Halant)
|
if (start != main && end > start+1 && lexical(pwChar[start]) == lex_Ra && lexical(pwChar[start+1]) == lex_Halant)
|
||||||
{
|
{
|
||||||
int j,loc;
|
int j,loc;
|
||||||
WORD Ra = pwChar[start];
|
WORD Ra = pwChar[start];
|
||||||
WORD H = pwChar[start+1];
|
WORD H = pwChar[start+1];
|
||||||
for (loc = main; loc > end; loc++)
|
for (loc = end; loc > main; loc--)
|
||||||
if (lexical(pwChar[loc]) == lex_Matra_post)
|
if (lexical(pwChar[loc]) == lex_Matra_post || lexical(pwChar[loc]) == lex_Matra_below)
|
||||||
break;
|
break;
|
||||||
if (loc == end) loc = main;
|
|
||||||
|
|
||||||
TRACE("Doing reorder of Ra to %i\n",loc);
|
TRACE("Doing reorder of Ra to %i\n",loc);
|
||||||
for (j = start; j < loc-1; j++)
|
for (j = start; j < loc-1; j++)
|
||||||
|
@ -1958,7 +1957,7 @@ static void Reorder_Like_Devanagari(LPWSTR pwChar, INT start, INT main, INT end,
|
||||||
main = Indic_FindBaseConsonant(pwChar, start, main, end, lexical);
|
main = Indic_FindBaseConsonant(pwChar, start, main, end, lexical);
|
||||||
if (lexical(pwChar[main]) == lex_Vowel) return;
|
if (lexical(pwChar[main]) == lex_Vowel) return;
|
||||||
|
|
||||||
Reorder_Ra_follows_matra_post(pwChar, start, main, end, lexical);
|
Reorder_Ra_follows_matra(pwChar, start, main, end, lexical);
|
||||||
Reorder_Matra_precede_syllable(pwChar, start, main, end, lexical);
|
Reorder_Matra_precede_syllable(pwChar, start, main, end, lexical);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1994,7 +1993,7 @@ static void Reorder_Like_Malayalam(LPWSTR pwChar, INT start, INT main, INT end,
|
||||||
main = Indic_FindBaseConsonant(pwChar, start, main, end, lexical);
|
main = Indic_FindBaseConsonant(pwChar, start, main, end, lexical);
|
||||||
if (lexical(pwChar[main]) == lex_Vowel) return;
|
if (lexical(pwChar[main]) == lex_Vowel) return;
|
||||||
|
|
||||||
Reorder_Ra_follows_matra_post(pwChar, start, main, end, lexical);
|
Reorder_Ra_follows_matra(pwChar, start, main, end, lexical);
|
||||||
Reorder_Matra_precede_base(pwChar, start, main, end, lexical);
|
Reorder_Matra_precede_base(pwChar, start, main, end, lexical);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue