summaryrefslogtreecommitdiff
path: root/modules/arabic
diff options
context:
space:
mode:
authorBehdad Esfahbod <behdad@gnome.org>2007-05-15 23:29:32 +0000
committerBehdad Esfahbod <behdad@src.gnome.org>2007-05-15 23:29:32 +0000
commit18e700760e42c18aa4a2f752f184ce1454d4cd82 (patch)
treeffdf2175852eaf6822480a1e673bbc5832715e7b /modules/arabic
parent92b13f8b4399582b66f31ccf804ad27a3145c433 (diff)
downloadpango-18e700760e42c18aa4a2f752f184ce1454d4cd82.tar.gz
Move ruleset creation after populating buffer.
2007-05-15 Behdad Esfahbod <behdad@gnome.org> * modules/arabic/arabic-fc.c (arabic_engine_shape): * modules/basic/basic-fc.c (basic_engine_shape): * modules/syriac/syriac-fc.c (syriac_engine_shape): Move ruleset creation after populating buffer. svn path=/trunk/; revision=2303
Diffstat (limited to 'modules/arabic')
-rw-r--r--modules/arabic/arabic-fc.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/modules/arabic/arabic-fc.c b/modules/arabic/arabic-fc.c
index a9bee35b..9635278b 100644
--- a/modules/arabic/arabic-fc.c
+++ b/modules/arabic/arabic-fc.c
@@ -105,20 +105,6 @@ arabic_engine_shape (PangoEngineShape *engine,
if (!face)
return;
- desc.script = analysis->script;
- desc.language = analysis->language;
-
- desc.n_static_gsub_features = G_N_ELEMENTS (gsub_features);
- desc.static_gsub_features = gsub_features;
- desc.n_static_gpos_features = G_N_ELEMENTS (gpos_features);
- desc.static_gpos_features = gpos_features;
-
- /* TODO populate other_features from analysis->extra_attrs */
- desc.n_other_features = 0;
- desc.other_features = NULL;
-
- ruleset = pango_ot_ruleset_get_for (pango_ot_info_get (face), &desc);
-
buffer = pango_ot_buffer_new (fc_font);
pango_ot_buffer_set_rtl (buffer, analysis->level % 2 != 0);
pango_ot_buffer_set_zero_width_marks (buffer, TRUE);
@@ -174,6 +160,20 @@ arabic_engine_shape (PangoEngineShape *engine,
g_free (properties);
+ desc.script = analysis->script;
+ desc.language = analysis->language;
+
+ desc.n_static_gsub_features = G_N_ELEMENTS (gsub_features);
+ desc.static_gsub_features = gsub_features;
+ desc.n_static_gpos_features = G_N_ELEMENTS (gpos_features);
+ desc.static_gpos_features = gpos_features;
+
+ /* TODO populate other_features from analysis->extra_attrs */
+ desc.n_other_features = 0;
+ desc.other_features = NULL;
+
+ ruleset = pango_ot_ruleset_get_for (pango_ot_info_get (face), &desc);
+
pango_ot_ruleset_substitute (ruleset, buffer);
pango_ot_ruleset_position (ruleset, buffer);
pango_ot_buffer_output (buffer, glyphs);