mirror of
https://github.com/VincentWei/MiniGUI.git
synced 2026-09-25 19:13:46 +08:00
fix a bug which may cause invalid values in log_clusters
This commit is contained in:
+4
-4
@@ -511,11 +511,11 @@ static void shape_space(const LAYOUT* layout, const LayoutRun* lrun,
|
||||
|
||||
gstr->glyphs[i].is_cluster_start = 1;
|
||||
gstr->log_clusters[i] = i;
|
||||
}
|
||||
|
||||
if (BIDI_LEVEL_IS_RTL(lrun->el) && gstr->nr_glyphs > 1) {
|
||||
__mg_reverse_shaped_glyphs(gstr->glyphs, gstr->nr_glyphs);
|
||||
__mg_reverse_log_clusters(gstr->log_clusters, gstr->nr_glyphs);
|
||||
}
|
||||
if (BIDI_LEVEL_IS_RTL(lrun->el) && gstr->nr_glyphs > 1) {
|
||||
__mg_reverse_shaped_glyphs(gstr->glyphs, gstr->nr_glyphs);
|
||||
__mg_reverse_log_clusters(gstr->log_clusters, gstr->nr_glyphs);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -254,7 +254,6 @@ static BOOL shape_layout_run(SEInstance* inst,
|
||||
gs->log_clusters[j] = i;
|
||||
j++;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
gs->nr_glyphs = j;
|
||||
|
||||
Reference in New Issue
Block a user