diff options
author | Behdad Esfahbod <behdad@gnome.org> | 2007-01-16 20:07:35 +0000 |
---|---|---|
committer | Behdad Esfahbod <behdad@src.gnome.org> | 2007-01-16 20:07:35 +0000 |
commit | 80e647a8dbc97662b9d966c0f7a8e1aedea89eed (patch) | |
tree | d3a322c28112b7623765847aa32e8e319c576b45 /modules/syriac | |
parent | e6b83e4264b4ad2ab73a3239d902b4064c75634d (diff) | |
download | pango-80e647a8dbc97662b9d966c0f7a8e1aedea89eed.tar.gz |
*.c, *.h: Drop trailing whitespace.
2007-01-16 Behdad Esfahbod <behdad@gnome.org>
*.c, *.h: Drop trailing whitespace.
svn path=/trunk/; revision=2163
Diffstat (limited to 'modules/syriac')
-rw-r--r-- | modules/syriac/syriac-fc.c | 48 | ||||
-rw-r--r-- | modules/syriac/syriac-ot.c | 54 | ||||
-rw-r--r-- | modules/syriac/syriac-ot.h | 8 |
3 files changed, 55 insertions, 55 deletions
diff --git a/modules/syriac/syriac-fc.c b/modules/syriac/syriac-fc.c index 51260838..985f0040 100644 --- a/modules/syriac/syriac-fc.c +++ b/modules/syriac/syriac-fc.c @@ -59,7 +59,7 @@ maybe_add_gsub_feature (PangoOTRuleset *ruleset, gulong property_bit) { guint feature_index; - + /* 0xffff == default language system */ if (pango_ot_info_find_feature (info, PANGO_OT_TABLE_GSUB, tag, script_index, 0xffff, &feature_index)) @@ -75,7 +75,7 @@ maybe_add_gpos_feature (PangoOTRuleset *ruleset, gulong property_bit) { guint feature_index; - + /* 0xffff == default language system */ if (pango_ot_info_find_feature (info, PANGO_OT_TABLE_GPOS, tag, script_index, 0xffff, &feature_index)) @@ -93,7 +93,7 @@ get_ruleset (FT_Face face) if (!ruleset_quark) ruleset_quark = g_quark_from_string ("pango-syriac-ruleset"); - + if (!info) return NULL; @@ -107,7 +107,7 @@ get_ruleset (FT_Face face) ruleset = pango_ot_ruleset_new (info); #define ALL_GLYPHS ~(gulong)0 - + if (pango_ot_info_find_script (info, PANGO_OT_TABLE_GSUB, syrc_tag, &script_index)) { @@ -144,16 +144,16 @@ static void swap_range (PangoGlyphString *glyphs, int start, int end) { int i, j; - + for (i = start, j = end - 1; i < j; i++, j--) { PangoGlyphInfo glyph_info; gint log_cluster; - + glyph_info = glyphs->glyphs[i]; glyphs->glyphs[i] = glyphs->glyphs[j]; glyphs->glyphs[j] = glyph_info; - + log_cluster = glyphs->log_clusters[i]; glyphs->log_clusters[i] = glyphs->log_clusters[j]; glyphs->log_clusters[j] = log_cluster; @@ -171,7 +171,7 @@ set_glyph (PangoFont *font, glyphs->log_clusters[i] = offset; } -static void +static void fallback_shape (PangoEngineShape *engine, PangoFont *font, const char *text, @@ -183,10 +183,10 @@ fallback_shape (PangoEngineShape *engine, glong n_chars = g_utf8_strlen (text, length); const char *p; int i; - + pango_glyph_string_set_size (glyphs, n_chars); p = text; - + for (i=0; i < n_chars; i++) { gunichar wc; @@ -212,7 +212,7 @@ fallback_shape (PangoEngineShape *engine, set_glyph (font, glyphs, i, p - text, index); } - + p = g_utf8_next_char (p); } @@ -222,17 +222,17 @@ fallback_shape (PangoEngineShape *engine, if (glyphs->glyphs[i].glyph) { PangoRectangle logical_rect; - + pango_font_get_glyph_extents (font, glyphs->glyphs[i].glyph, NULL, &logical_rect); glyphs->glyphs[i].geometry.width = logical_rect.width; } else glyphs->glyphs[i].geometry.width = 0; - + glyphs->glyphs[i].geometry.x_offset = 0; glyphs->glyphs[i].geometry.y_offset = 0; } - + if (analysis->level % 2 != 0) { /* Swap all glyphs */ @@ -240,7 +240,7 @@ fallback_shape (PangoEngineShape *engine, } } -static void +static void syriac_engine_shape (PangoEngineShape *engine, PangoFont *font, const char *text, @@ -279,14 +279,14 @@ syriac_engine_shape (PangoEngineShape *engine, 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); - + wcs = g_utf8_to_ucs4_fast (text, length, &n_chars); properties = g_new0 (gulong, n_chars); - + syriac_assign_properties (wcs, properties, n_chars); g_free (wcs); - + p = text; for (i=0; i < n_chars; i++) { @@ -317,19 +317,19 @@ syriac_engine_shape (PangoEngineShape *engine, { if (g_unichar_type (wc) != G_UNICODE_NON_SPACING_MARK) cluster = p - text; - + pango_ot_buffer_add_glyph (buffer, index, properties[i], cluster); } } - + p = g_utf8_next_char (p); } pango_ot_ruleset_substitute (ruleset, buffer); pango_ot_ruleset_position (ruleset, buffer); pango_ot_buffer_output (buffer, glyphs); - + g_free (properties); pango_ot_buffer_destroy (buffer); @@ -346,18 +346,18 @@ syriac_engine_fc_class_init (PangoEngineShapeClass *class) PANGO_ENGINE_SHAPE_DEFINE_TYPE (SyriacEngineFc, syriac_engine_fc, syriac_engine_fc_class_init, NULL) -void +void PANGO_MODULE_ENTRY(init) (GTypeModule *module) { syriac_engine_fc_register_type (module); } -void +void PANGO_MODULE_ENTRY(exit) (void) { } -void +void PANGO_MODULE_ENTRY(list) (PangoEngineInfo **engines, int *n_engines) { diff --git a/modules/syriac/syriac-ot.c b/modules/syriac/syriac-ot.c index a2489bc0..4650c9da 100644 --- a/modules/syriac/syriac-ot.c +++ b/modules/syriac/syriac-ot.c @@ -7,7 +7,7 @@ * * This file is based on the Arabic shaping code from FreeType 1 tree; original * copyright notice: - * + * * The FreeType project -- a free and portable quality TrueType renderer. * * Copyright 1996-2000 by @@ -36,7 +36,7 @@ static const JoiningClass syriac[] = none, none, none, none, none, none, none, none, none, none, none, transparent, - + /* U+0710 */ right, none, dual, dual, dual, right, right, right, @@ -83,7 +83,7 @@ Get_Joining_Class (gunichar* string, if (pos >= length) return none; - + if (string[pos] < 0x0700 || string[pos] >= 0x074F) { @@ -91,10 +91,10 @@ Get_Joining_Class (gunichar* string, return causing; else return none; - } + } else j = syriac[string[pos] - 0x0700]; - + if (!direction || j != transparent) return j; } @@ -106,7 +106,7 @@ Get_Joining_Class (gunichar* string, * with the Syriac rules from the Unicode-4.0 standard. The numbers * R1...R11 below do not correspond to either the Arabic or the Syriac * rule numbering from the Unicode standard. - * + * * Characters are here specified as appearing in the byte stream, i.e. * *not* in visual order. Joining classes are given in angle brackets, * glyph forms in square brackets. Glyphs affected by a specific rule are @@ -115,10 +115,10 @@ Get_Joining_Class (gunichar* string, * * Glyphs: 0x0715 (Dalath), 0x0716 (Dalath Rish), 0x072A (Rish), * 0x0722 (Nun), 0x071F (Kaph) - * + * * * R1: <anything1> <transparent> <anything2> - * + * * apply joining rules for * <anything1> <anything2> -> [shape1] [shape2] * -> [shape1] [isolated] [shape2] @@ -139,25 +139,25 @@ Get_Joining_Class (gunichar* string, * * * R3: <causing|right|dual> && <!(0x0715|0x0716|0x072A)> |<alaph>| - * + * * -> [final2] * - * If the preceding glyph cannot be joined to the current - * glyph and the preceding character is not a Dalath, Rish, - * or Dotless Dalath Rish, then the Alaph takes this contextual + * If the preceding glyph cannot be joined to the current + * glyph and the preceding character is not a Dalath, Rish, + * or Dotless Dalath Rish, then the Alaph takes this contextual * position. * * The [final2] joining rule is placed ahead of the [final] to * give it greater precedence when choosing the correct glyph. * If it comes after the [final] rule, the incorrect glyph is * inserted into position. - * - * + * + * * R4: <0x0715|0x0715|0x072A> |<alaph>| * * -> [final3] * - * If the previous glyph is a Dalath, Rish, or Dotless Dalath + * If the previous glyph is a Dalath, Rish, or Dotless Dalath * Rish, then the Alaph takes this contextual position. * * The [final3] joining rule is placed ahead of the [final] to @@ -169,13 +169,13 @@ Get_Joining_Class (gunichar* string, * R5: <causing|right|dual> |<right>| * * -> [final] - * - * + * + * * R6: <causing|right|dual> |<dual>| <!(causing|right|dual)> * * -> [final] - * - * + * + * * R7: <causing|left|dual> |<dual>| <causing|right|dual> * * -> [medial] @@ -185,10 +185,10 @@ Get_Joining_Class (gunichar* string, * * -> [medial2] * - * If the Alaph glyph falls in the middle of a Syriac word and - * the preceding character cannot be joined to, then the Alaph + * If the Alaph glyph falls in the middle of a Syriac word and + * the preceding character cannot be joined to, then the Alaph * takes this contextual position. - * + * * * R9: |<left>| <causing|right|dual> * @@ -238,7 +238,7 @@ syriac_assign_properties (gunichar *string, /* R2 */ if (string[i] == 0x0722 || - string[i] == 0x071F) + string[i] == 0x071F) if (previous == causing || previous == right) if (!(next == causing || @@ -270,7 +270,7 @@ syriac_assign_properties (gunichar *string, if (string[i - 1] == 0x0715 || string[i - 1] == 0x0716 || string[i - 1] == 0x072A) - { + { properties[i] |= final3_p; continue; } @@ -280,7 +280,7 @@ syriac_assign_properties (gunichar *string, if (previous == causing || previous == right || previous == dual) - if (current == right) + if (current == right) { properties[i] |= final_p; continue; @@ -352,10 +352,10 @@ syriac_assign_properties (gunichar *string, continue; } - /* R11 */ + /* R11 */ properties[i] |= isolated_p; } - + return FT_Err_Ok; } diff --git a/modules/syriac/syriac-ot.h b/modules/syriac/syriac-ot.h index 17efd18e..e9aea543 100644 --- a/modules/syriac/syriac-ot.h +++ b/modules/syriac/syriac-ot.h @@ -7,7 +7,7 @@ * * This file is based on the Arabic shaping code from FreeType 1 tree; original * copyright notice: - * + * * The FreeType project -- a free and portable quality TrueType renderer. * * Copyright 1996-2000 by @@ -15,7 +15,7 @@ * * The code, like the FreeType code it is derived from is dual-licensed * under the GNU Public License and the FreeType license. See see - * pango/opentype/FT-license.txt for full details of the FreeType + * pango/opentype/FT-license.txt for full details of the FreeType * license. */ @@ -26,7 +26,7 @@ G_BEGIN_DECLS -typedef enum +typedef enum { isolated = 1 << 0, /* nominal */ final = 1 << 1, /* right_joining */ @@ -50,7 +50,7 @@ typedef enum final3_p = isolated | final | initial | medial | medial2 | final2 } SyriacGlyphForm; -typedef enum +typedef enum { right, left, /* not used */ |