mirror of
git://source.winehq.org/git/wine.git
synced 2024-11-02 20:18:28 +00:00
usp10: pwLogClust is ordered so its max will be on one end.
This commit is contained in:
parent
1967fae847
commit
2ab625bf2f
1 changed files with 5 additions and 7 deletions
|
@ -2309,16 +2309,14 @@ static inline int get_cluster_size(const WORD *pwLogClust, int cChars, int item,
|
|||
static inline int get_glyph_cluster_advance(const int* piAdvance, const SCRIPT_VISATTR *pva, const WORD *pwLogClust, int cGlyphs, int cChars, int glyph, int direction)
|
||||
{
|
||||
int advance;
|
||||
int log_clust_max = 0;
|
||||
int i;
|
||||
int log_clust_max;
|
||||
|
||||
advance = piAdvance[glyph];
|
||||
|
||||
for (i = 0; i < cChars; i++)
|
||||
{
|
||||
if (pwLogClust[i] > log_clust_max)
|
||||
log_clust_max = pwLogClust[i];
|
||||
}
|
||||
if (pwLogClust[0] > pwLogClust[cChars-1])
|
||||
log_clust_max = pwLogClust[0];
|
||||
else
|
||||
log_clust_max = pwLogClust[cChars-1];
|
||||
|
||||
if (glyph > log_clust_max)
|
||||
return advance;
|
||||
|
|
Loading…
Reference in a new issue