Rename the GUTILS_C_VAR macro to GLIB_VAR.
[platform/upstream/glib.git] / glib.h
diff --git a/glib.h b/glib.h
index 23aa72c..d7ac6d5 100644 (file)
--- a/glib.h
+++ b/glib.h
@@ -500,6 +500,7 @@ typedef short  gshort;
 typedef long   glong;
 typedef int    gint;
 typedef gint   gboolean;
+typedef gchar* gstring;
 
 typedef unsigned char  guchar;
 typedef unsigned short gushort;
@@ -697,19 +698,19 @@ typedef gint32    GTime;
  */
 #ifdef G_OS_WIN32
 #  ifdef GLIB_COMPILATION
-#    define GUTILS_C_VAR __declspec(dllexport)
+#    define GLIB_VAR __declspec(dllexport)
 #  else /* !GLIB_COMPILATION */
-#    define GUTILS_C_VAR extern __declspec(dllimport)
+#    define GLIB_VAR extern __declspec(dllimport)
 #  endif /* !GLIB_COMPILATION */
 #else /* !G_OS_WIN32 */
-#  define GUTILS_C_VAR extern
+#  define GLIB_VAR extern
 #endif /* !G_OS_WIN32 */
 
-GUTILS_C_VAR const guint glib_major_version;
-GUTILS_C_VAR const guint glib_minor_version;
-GUTILS_C_VAR const guint glib_micro_version;
-GUTILS_C_VAR const guint glib_interface_age;
-GUTILS_C_VAR const guint glib_binary_age;
+GLIB_VAR const guint glib_major_version;
+GLIB_VAR const guint glib_minor_version;
+GLIB_VAR const guint glib_micro_version;
+GLIB_VAR const guint glib_interface_age;
+GLIB_VAR const guint glib_binary_age;
 
 #define GLIB_CHECK_VERSION(major,minor,micro)    \
     (GLIB_MAJOR_VERSION > (major) || \
@@ -1708,6 +1709,9 @@ gchar*  g_path_skip_root  (gchar       *file_name);
 gchar* g_dirname               (const gchar *file_name);
 gchar* g_get_current_dir       (void);
 
+/* Get the codeset for the current locale */
+/* gchar * g_get_codeset    (void); */
+
 /* return the environment string for the variable. The returned memory
  * must not be freed. */
 gchar*  g_getenv               (const gchar *variable);
@@ -1861,10 +1865,13 @@ GString*     g_string_new               (const gchar     *init);
 GString*     g_string_sized_new         (guint           dfl_size);
 void        g_string_free              (GString         *string,
                                         gboolean         free_segment);
+gboolean     g_string_equal             (const GString  *v,
+                                        const GString   *v2);
+guint        g_string_hash              (const GString   *str);
 GString*     g_string_assign            (GString        *string,
                                         const gchar     *rval);
 GString*     g_string_truncate          (GString        *string,
-                                        gint             len);
+                                        guint            len);
 GString*     g_string_insert_len        (GString         *string,
                                          gint             pos,
                                          const gchar     *val,
@@ -1985,13 +1992,13 @@ GByteArray* g_byte_array_remove_index_fast (GByteArray   *array,
 
 /* Hash Functions
  */
-gint  g_str_equal (gconstpointer   v,
-                  gconstpointer   v2);
-guint g_str_hash  (gconstpointer   v);
+gboolean g_str_equal (gconstpointer   v,
+                     gconstpointer   v2);
+guint   g_str_hash  (gconstpointer   v);
 
-gint  g_int_equal (gconstpointer   v,
-                  gconstpointer   v2);
-guint g_int_hash  (gconstpointer   v);
+gint    g_int_equal (gconstpointer   v,
+                     gconstpointer   v2);
+guint   g_int_hash  (gconstpointer   v);
 
 /* This "hash" function will just return the key's adress as an
  * unsigned integer. Useful for hashing on plain adresses or
@@ -2826,7 +2833,7 @@ gint        g_io_channel_unix_get_fd (GIOChannel *channel);
 
 #ifdef G_OS_WIN32
 
-GUTILS_C_VAR guint g_pipe_readable_msg;
+GLIB_VAR guint g_pipe_readable_msg;
 
 #define G_WIN32_MSG_HANDLE 19981206
 
@@ -3021,9 +3028,9 @@ struct _GThreadFunctions
   void      (*thread_self)        (gpointer              thread);
 };
 
-GUTILS_C_VAR GThreadFunctions  g_thread_functions_for_glib_use;
-GUTILS_C_VAR gboolean          g_thread_use_default_impl;
-GUTILS_C_VAR gboolean          g_threads_got_initialized;
+GLIB_VAR GThreadFunctions      g_thread_functions_for_glib_use;
+GLIB_VAR gboolean              g_thread_use_default_impl;
+GLIB_VAR gboolean              g_threads_got_initialized;
 
 /* initializes the mutex/cond/private implementation for glib, might
  * only be called once, and must not be called directly or indirectly
@@ -3318,9 +3325,10 @@ guint           g_thread_pool_get_num_unused_threads (void);
 /* Stop all currently unused threads, but leave the limit untouched */
 void            g_thread_pool_stop_unused_threads    (void);
 
+#include <gunicode.h>
+
 #ifdef __cplusplus
 }
 #endif /* __cplusplus */
 
-
 #endif /* __G_LIB_H__ */