[pango/harfbuzz-ng] [HB] Use enums



commit 51d81548dd52fbb6c90775eb3bc83289c0329ddf
Author: Behdad Esfahbod <behdad behdad org>
Date:   Mon May 18 18:44:54 2009 -0400

    [HB] Use enums
---
 pango/opentype/hb-ot-layout-common-private.h |   14 ++++++++------
 pango/opentype/hb-ot-layout-gdef-private.h   |   22 +++++++++++++---------
 2 files changed, 21 insertions(+), 15 deletions(-)

diff --git a/pango/opentype/hb-ot-layout-common-private.h b/pango/opentype/hb-ot-layout-common-private.h
index 074b26a..50fdc44 100644
--- a/pango/opentype/hb-ot-layout-common-private.h
+++ b/pango/opentype/hb-ot-layout-common-private.h
@@ -165,12 +165,14 @@ ASSERT_SIZE (FeatureList, 2);
 
 
 struct LookupFlag : USHORT {
-  static const unsigned int RightToLeft		= 0x0001u;
-  static const unsigned int IgnoreBaseGlyphs	= 0x0002u;
-  static const unsigned int IgnoreLigatures	= 0x0004u;
-  static const unsigned int IgnoreMarks		= 0x0008u;
-  static const unsigned int Reserved		= 0x00F0u;
-  static const unsigned int MarkAttachmentType	= 0xFF00u;
+  enum {
+    RightToLeft		= 0x0001u,
+    IgnoreBaseGlyphs	= 0x0002u,
+    IgnoreLigatures	= 0x0004u,
+    IgnoreMarks		= 0x0008u,
+    Reserved		= 0x00F0u,
+    MarkAttachmentType	= 0xFF00u,
+  };
 };
 ASSERT_SIZE (LookupFlag, 2);
 
diff --git a/pango/opentype/hb-ot-layout-gdef-private.h b/pango/opentype/hb-ot-layout-gdef-private.h
index 19f0e8e..601424d 100644
--- a/pango/opentype/hb-ot-layout-gdef-private.h
+++ b/pango/opentype/hb-ot-layout-gdef-private.h
@@ -37,10 +37,12 @@
 
 
 struct GlyphClassDef : ClassDef {
-  static const unsigned int BaseGlyph		= 0x0001u;
-  static const unsigned int LigatureGlyph	= 0x0002u;
-  static const unsigned int MarkGlyph		= 0x0003u;
-  static const unsigned int ComponentGlyph	= 0x0004u;
+  enum {
+    BaseGlyph		= 0x0001u,
+    LigatureGlyph	= 0x0002u,
+    MarkGlyph		= 0x0003u,
+    ComponentGlyph	= 0x0004u,
+  };
 };
 
 /*
@@ -182,11 +184,13 @@ ASSERT_SIZE (LigCaretList, 4);
 struct GDEF {
   static const hb_tag_t Tag		= HB_TAG ('G','D','E','F');
 
-  static const hb_ot_layout_class_t UnclassifiedGlyph	= 0;
-  static const hb_ot_layout_class_t BaseGlyph		= 1;
-  static const hb_ot_layout_class_t LigatureGlyph	= 2;
-  static const hb_ot_layout_class_t MarkGlyph		= 3;
-  static const hb_ot_layout_class_t ComponentGlyph	= 4;
+  enum {
+    UnclassifiedGlyph	= 0,
+    BaseGlyph		= 1,
+    LigatureGlyph	= 2,
+    MarkGlyph		= 3,
+    ComponentGlyph	= 4,
+  };
 
   STATIC_DEFINE_GET_FOR_DATA (GDEF);
   /* XXX check version here? */



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]