From: Behdad Esfahbod Date: Thu, 21 Jul 2011 16:00:36 +0000 (-0400) Subject: [HB] Fix cluster setting with recent HB change X-Git-Tag: 1.31.0~19^2~6 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=26475e516f2384efaefe3dd97bd99f2176291354;p=platform%2Fupstream%2Fpango.git [HB] Fix cluster setting with recent HB change --- diff --git a/modules/basic/basic-fc.c b/modules/basic/basic-fc.c index 4283247..e1e7aa1 100644 --- a/modules/basic/basic-fc.c +++ b/modules/basic/basic-fc.c @@ -293,7 +293,14 @@ basic_engine_shape (PangoEngineShape *engine G_GNUC_UNUSED, for (i = 0; i < num_glyphs; i++) { glyphs->glyphs[i].glyph = hb_glyph->codepoint; - glyphs->log_clusters[i] = hb_glyph->cluster; + if (i && glyphs->log_clusters[i-1] != hb_glyph->cluster) { + GUnicodeType t = g_unichar_type (g_utf8_get_char (text + hb_glyph->cluster)); + if ((1<log_clusters[i] = last_cluster; + else + glyphs->log_clusters[i] = hb_glyph->cluster; + } else + glyphs->log_clusters[i] = hb_glyph->cluster; glyphs->glyphs[i].attr.is_cluster_start = glyphs->log_clusters[i] != last_cluster; last_cluster = glyphs->log_clusters[i];