Go to the documentation of this file.
94 #define G_DIR_SEPARATOR '\\'
95 #define G_DIR_SEPARATOR_S "\\"
96 #define G_SEARCHPATH_SEPARATOR ';'
97 #define G_SEARCHPATH_SEPARATOR_S ";"
103 #define G_DIR_SEPARATOR '/'
104 #define G_DIR_SEPARATOR_S "/"
105 #define G_SEARCHPATH_SEPARATOR ':'
106 #define G_SEARCHPATH_SEPARATOR_S ":"
121 #define NULL ((void*) 0)
129 #define TRUE (!FALSE)
133 #define MAX(a, b) (((a) > (b)) ? (a) : (b))
136 #define MIN(a, b) (((a) < (b)) ? (a) : (b))
139 #define ABS(a) (((a) < 0) ? -(a) : (a))
142 #define CLAMP(x, low, high) (((x) > (high)) ? (high) : (((x) < (low)) ? (low) : (x)))
148 #if !defined (G_VA_COPY)
149 # if defined (__GNUC__) && defined (__PPC__) && (defined (_CALL_SYSV) || defined (_WIN32))
150 # define G_VA_COPY(ap1, ap2) (*(ap1) = *(ap2))
151 # elif defined (G_VA_COPY_AS_ARRAY)
152 # define G_VA_COPY(ap1, ap2) g_memmove ((ap1), (ap2), sizeof (va_list))
154 # define G_VA_COPY(ap1, ap2) ((ap1) = (ap2))
162 #define G_STRUCT_OFFSET(struct_type, member) \
163 ((gulong) ((gchar*) &((struct_type*) 0)->member))
164 #define G_STRUCT_MEMBER_P(struct_p, struct_offset) \
165 ((gpointer) ((gchar*) (struct_p) + (gulong) (struct_offset)))
166 #define G_STRUCT_MEMBER(member_type, struct_p, struct_offset) \
167 (*(member_type*) G_STRUCT_MEMBER_P ((struct_p), (struct_offset)))
180 #ifndef G_INLINE_FUNC
181 # define G_CAN_INLINE 1
184 # if defined (__GNUC__) && defined (__STRICT_ANSI__)
186 # define inline __inline__
190 # if defined (G_HAVE___INLINE__)
191 # define inline __inline__
193 # if defined (G_HAVE___INLINE)
194 # define inline __inline
197 # ifndef G_INLINE_FUNC
203 #ifndef G_INLINE_FUNC
206 # define G_INLINE_FUNC extern inline
209 # define G_INLINE_FUNC extern
213 # define G_INLINE_FUNC static inline
215 # define G_INLINE_FUNC extern
230 #if !(defined (G_STMT_START) && defined (G_STMT_END))
231 # if defined (__GNUC__) && !defined (__STRICT_ANSI__) && !defined (__cplusplus)
232 # define G_STMT_START (void)(
233 # define G_STMT_END )
235 # if (defined (sun) || defined (__sun__))
236 # define G_STMT_START if (1)
237 # define G_STMT_END else (void)0
239 # define G_STMT_START do
240 # define G_STMT_END while (0)
248 #if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ > 4)
249 #define G_GNUC_PRINTF( format_idx, arg_idx ) \
250 __attribute__((format (printf, format_idx, arg_idx)))
251 #define G_GNUC_SCANF( format_idx, arg_idx ) \
252 __attribute__((format (scanf, format_idx, arg_idx)))
253 #define G_GNUC_FORMAT( arg_idx ) \
254 __attribute__((format_arg (arg_idx)))
255 #define G_GNUC_NORETURN \
256 __attribute__((noreturn))
257 #define G_GNUC_CONST \
258 __attribute__((const))
259 #define G_GNUC_UNUSED \
260 __attribute__((unused))
262 #define G_GNUC_PRINTF( format_idx, arg_idx )
263 #define G_GNUC_SCANF( format_idx, arg_idx )
264 #define G_GNUC_FORMAT( arg_idx )
265 #define G_GNUC_NORETURN
267 #define G_GNUC_UNUSED
275 #define G_GNUC_FUNCTION __FUNCTION__
276 #define G_GNUC_PRETTY_FUNCTION __PRETTY_FUNCTION__
278 #define G_GNUC_FUNCTION ""
279 #define G_GNUC_PRETTY_FUNCTION ""
287 # define ATEXIT(proc) g_ATEXIT(proc)
289 # define G_NATIVE_ATEXIT
295 #if defined (__i386__) && defined (__GNUC__) && __GNUC__ >= 2
296 #define G_BREAKPOINT() G_STMT_START{ __asm__ __volatile__ ("int $03"); }G_STMT_END
297 #elif defined (__alpha__) && defined (__GNUC__) && __GNUC__ >= 2
298 #define G_BREAKPOINT() G_STMT_START{ __asm__ __volatile__ ("bpt"); }G_STMT_END
300 #define G_BREAKPOINT()
309 # define g_new(type, count) \
310 ((type *) malloc ((unsigned) sizeof (type) * (count)))
311 # define g_new0(type, count) \
312 ((type *) calloc ((unsigned) sizeof (type) * (count), 1))
313 # define g_renew(type, mem, count) \
314 ((type *) realloc (mem, (unsigned) sizeof (type) * (count)))
316 #define g_mem_chunk_create(type, pre_alloc, alloc_type) ( \
317 g_mem_chunk_new (#type " mem chunks (" #pre_alloc ")", \
319 sizeof (type) * (pre_alloc), \
322 #define g_chunk_new(type, chunk) ( \
323 (type *) g_mem_chunk_alloc (chunk) \
325 #define g_chunk_new0(type, chunk) ( \
326 (type *) g_mem_chunk_alloc0 (chunk) \
328 #define g_chunk_free(mem, mem_chunk) G_STMT_START { \
329 g_mem_chunk_free ((mem_chunk), (mem)); \
333 #define g_string(x) #x
343 #ifdef G_DISABLE_ASSERT
345 #define g_assert(expr)
346 #define g_assert_not_reached()
352 #define g_assert(expr) G_STMT_START{ \
354 g_log (G_LOG_DOMAIN, \
356 "file %s: line %d (%s): assertion failed: (%s)", \
359 __PRETTY_FUNCTION__, \
362 #define g_assert_not_reached() G_STMT_START{ \
363 g_log (G_LOG_DOMAIN, \
365 "file %s: line %d (%s): should not be reached", \
368 __PRETTY_FUNCTION__); }G_STMT_END
372 #define g_assert(expr) G_STMT_START{ \
374 g_log (G_LOG_DOMAIN, \
376 "file %s: line %d: assertion failed: (%s)", \
381 #define g_assert_not_reached() G_STMT_START{ \
382 g_log (G_LOG_DOMAIN, \
384 "file %s: line %d: should not be reached", \
386 __LINE__); }G_STMT_END
393 #ifdef G_DISABLE_CHECKS
395 #define g_return_if_fail(expr)
396 #define g_return_val_if_fail(expr,val)
402 #define g_return_if_fail(expr) G_STMT_START{ \
405 g_log (G_LOG_DOMAIN, \
406 G_LOG_LEVEL_CRITICAL, \
407 "file %s: line %d (%s): assertion `%s' failed.", \
410 __PRETTY_FUNCTION__, \
415 #define g_return_val_if_fail(expr,val) G_STMT_START{ \
418 g_log (G_LOG_DOMAIN, \
419 G_LOG_LEVEL_CRITICAL, \
420 "file %s: line %d (%s): assertion `%s' failed.", \
423 __PRETTY_FUNCTION__, \
430 #define g_return_if_fail(expr) G_STMT_START{ \
433 g_log (G_LOG_DOMAIN, \
434 G_LOG_LEVEL_CRITICAL, \
435 "file %s: line %d: assertion `%s' failed.", \
442 #define g_return_val_if_fail(expr, val) G_STMT_START{ \
445 g_log (G_LOG_DOMAIN, \
446 G_LOG_LEVEL_CRITICAL, \
447 "file %s: line %d: assertion `%s' failed.", \
484 #ifdef HAVE_LONG_DOUBLE
485 typedef long double gldouble;
487 typedef double gldouble;
506 #define G_LITTLE_ENDIAN 1234
507 #define G_BIG_ENDIAN 4321
508 #define G_PDP_ENDIAN 3412
513 #define GUINT16_SWAP_LE_BE_CONSTANT(val) ((guint16) ( \
514 (((guint16) (val) & (guint16) 0x00ffU) << 8) | \
515 (((guint16) (val) & (guint16) 0xff00U) >> 8)))
516 #define GUINT32_SWAP_LE_BE_CONSTANT(val) ((guint32) ( \
517 (((guint32) (val) & (guint32) 0x000000ffU) << 24) | \
518 (((guint32) (val) & (guint32) 0x0000ff00U) << 8) | \
519 (((guint32) (val) & (guint32) 0x00ff0000U) >> 8) | \
520 (((guint32) (val) & (guint32) 0xff000000U) >> 24)))
524 #if defined (__i386__) && defined (__GNUC__) && __GNUC__ >= 2
525 # define GUINT16_SWAP_LE_BE_X86(val) \
527 ({ register guint16 __v; \
528 if (__builtin_constant_p (val)) \
529 __v = GUINT16_SWAP_LE_BE_CONSTANT (val); \
531 __asm__ __const__ ("rorw $8, %w0" \
533 : "0" ((guint16) (val))); \
535 # define GUINT16_SWAP_LE_BE(val) (GUINT16_SWAP_LE_BE_X86 (val))
536 # if !defined(__i486__) && !defined(__i586__) \
537 && !defined(__pentium__) && !defined(__i686__) && !defined(__pentiumpro__)
538 # define GUINT32_SWAP_LE_BE_X86(val) \
540 ({ register guint32 __v; \
541 if (__builtin_constant_p (val)) \
542 __v = GUINT32_SWAP_LE_BE_CONSTANT (val); \
544 __asm__ __const__ ("rorw $8, %w0\n\t" \
548 : "0" ((guint32) (val))); \
551 # define GUINT32_SWAP_LE_BE_X86(val) \
553 ({ register guint32 __v; \
554 if (__builtin_constant_p (val)) \
555 __v = GUINT32_SWAP_LE_BE_CONSTANT (val); \
557 __asm__ __const__ ("bswap %0" \
559 : "0" ((guint32) (val))); \
562 # define GUINT32_SWAP_LE_BE(val) (GUINT32_SWAP_LE_BE_X86 (val))
564 # define GUINT16_SWAP_LE_BE(val) (GUINT16_SWAP_LE_BE_CONSTANT (val))
565 # define GUINT32_SWAP_LE_BE(val) (GUINT32_SWAP_LE_BE_CONSTANT (val))
569 # define GUINT64_SWAP_LE_BE_CONSTANT(val) ((guint64) ( \
570 (((guint64) (val) & \
571 (guint64) G_GINT64_CONSTANT(0x00000000000000ffU)) << 56) | \
572 (((guint64) (val) & \
573 (guint64) G_GINT64_CONSTANT(0x000000000000ff00U)) << 40) | \
574 (((guint64) (val) & \
575 (guint64) G_GINT64_CONSTANT(0x0000000000ff0000U)) << 24) | \
576 (((guint64) (val) & \
577 (guint64) G_GINT64_CONSTANT(0x00000000ff000000U)) << 8) | \
578 (((guint64) (val) & \
579 (guint64) G_GINT64_CONSTANT(0x000000ff00000000U)) >> 8) | \
580 (((guint64) (val) & \
581 (guint64) G_GINT64_CONSTANT(0x0000ff0000000000U)) >> 24) | \
582 (((guint64) (val) & \
583 (guint64) G_GINT64_CONSTANT(0x00ff000000000000U)) >> 40) | \
584 (((guint64) (val) & \
585 (guint64) G_GINT64_CONSTANT(0xff00000000000000U)) >> 56)))
586 # if defined (__i386__) && defined (__GNUC__) && __GNUC__ >= 2
587 # define GUINT64_SWAP_LE_BE_X86(val) \
589 ({ union { guint64 __ll; \
590 guint32 __l[2]; } __r; \
591 if (__builtin_constant_p (val)) \
592 __r.__ll = GUINT64_SWAP_LE_BE_CONSTANT (val); \
595 union { guint64 __ll; \
596 guint32 __l[2]; } __w; \
597 __w.__ll = ((guint64) val); \
598 __r.__l[0] = GUINT32_SWAP_LE_BE (__w.__l[1]); \
599 __r.__l[1] = GUINT32_SWAP_LE_BE (__w.__l[0]); \
602 # define GUINT64_SWAP_LE_BE(val) (GUINT64_SWAP_LE_BE_X86 (val))
604 # define GUINT64_SWAP_LE_BE(val) (GUINT64_SWAP_LE_BE_CONSTANT(val))
608 #define GUINT16_SWAP_LE_PDP(val) ((guint16) (val))
609 #define GUINT16_SWAP_BE_PDP(val) (GUINT16_SWAP_LE_BE (val))
610 #define GUINT32_SWAP_LE_PDP(val) ((guint32) ( \
611 (((guint32) (val) & (guint32) 0x0000ffffU) << 16) | \
612 (((guint32) (val) & (guint32) 0xffff0000U) >> 16)))
613 #define GUINT32_SWAP_BE_PDP(val) ((guint32) ( \
614 (((guint32) (val) & (guint32) 0x00ff00ffU) << 8) | \
615 (((guint32) (val) & (guint32) 0xff00ff00U) >> 8)))
620 #define GINT16_FROM_LE(val) (GINT16_TO_LE (val))
621 #define GUINT16_FROM_LE(val) (GUINT16_TO_LE (val))
622 #define GINT16_FROM_BE(val) (GINT16_TO_BE (val))
623 #define GUINT16_FROM_BE(val) (GUINT16_TO_BE (val))
624 #define GINT32_FROM_LE(val) (GINT32_TO_LE (val))
625 #define GUINT32_FROM_LE(val) (GUINT32_TO_LE (val))
626 #define GINT32_FROM_BE(val) (GINT32_TO_BE (val))
627 #define GUINT32_FROM_BE(val) (GUINT32_TO_BE (val))
630 #define GINT64_FROM_LE(val) (GINT64_TO_LE (val))
631 #define GUINT64_FROM_LE(val) (GUINT64_TO_LE (val))
632 #define GINT64_FROM_BE(val) (GINT64_TO_BE (val))
633 #define GUINT64_FROM_BE(val) (GUINT64_TO_BE (val))
636 #define GLONG_FROM_LE(val) (GLONG_TO_LE (val))
637 #define GULONG_FROM_LE(val) (GULONG_TO_LE (val))
638 #define GLONG_FROM_BE(val) (GLONG_TO_BE (val))
639 #define GULONG_FROM_BE(val) (GULONG_TO_BE (val))
641 #define GINT_FROM_LE(val) (GINT_TO_LE (val))
642 #define GUINT_FROM_LE(val) (GUINT_TO_LE (val))
643 #define GINT_FROM_BE(val) (GINT_TO_BE (val))
644 #define GUINT_FROM_BE(val) (GUINT_TO_BE (val))
649 #define g_ntohl(val) (GUINT32_FROM_BE (val))
650 #define g_ntohs(val) (GUINT16_FROM_BE (val))
651 #define g_htonl(val) (GUINT32_TO_BE (val))
652 #define g_htons(val) (GUINT16_TO_BE (val))
660 # ifdef GLIB_COMPILATION
661 # define GUTILS_C_VAR __declspec(dllexport)
663 # define GUTILS_C_VAR extern __declspec(dllimport)
666 # define GUTILS_C_VAR extern
675 #define GLIB_CHECK_VERSION(major,minor,micro) \
676 (GLIB_MAJOR_VERSION > (major) || \
677 (GLIB_MAJOR_VERSION == (major) && GLIB_MINOR_VERSION > (minor)) || \
678 (GLIB_MAJOR_VERSION == (major) && GLIB_MINOR_VERSION == (minor) && \
679 GLIB_MICRO_VERSION >= (micro)))
686 typedef struct _GCache
GCache;
688 typedef struct _GData
GData;
703 typedef struct _GTimer
GTimer;
704 typedef struct _GTree
GTree;
728 #define G_LOG_LEVEL_USER_SHIFT (8)
750 #define G_LOG_FATAL_MASK (G_LOG_FLAG_RECURSION | G_LOG_LEVEL_ERROR)
787 const gchar *message,
899 #define g_list_previous(list) ((list) ? (((GList *)(list))->prev) : NULL)
900 #define g_list_next(list) ((list) ? (((GList *)(list))->next) : NULL)
948 #define g_slist_next(slist) ((slist) ? (((GSList *)(slist))->next) : NULL)
1034 #define G_NODE_IS_ROOT(node) (((GNode*) (node))->parent == NULL && \
1035 ((GNode*) (node))->prev == NULL && \
1036 ((GNode*) (node))->next == NULL)
1037 #define G_NODE_IS_LEAF(node) (((GNode*) (node))->children == NULL)
1064 #define g_node_append(parent, node) \
1065 g_node_insert_before ((parent), NULL, (node))
1066 #define g_node_insert_data(parent, position, data) \
1067 g_node_insert ((parent), (position), g_node_new (data))
1068 #define g_node_insert_data_before(parent, sibling, data) \
1069 g_node_insert_before ((parent), (sibling), g_node_new (data))
1070 #define g_node_prepend_data(parent, data) \
1071 g_node_prepend ((parent), g_node_new (data))
1072 #define g_node_append_data(parent, data) \
1073 g_node_insert_before ((parent), NULL, g_node_new (data))
1114 #define g_node_prev_sibling(node) ((node) ? \
1115 ((GNode*) (node))->prev : NULL)
1116 #define g_node_next_sibling(node) ((node) ? \
1117 ((GNode*) (node))->next : NULL)
1118 #define g_node_first_child(node) ((node) ? \
1119 ((GNode*) (node))->children : NULL)
1124 #define G_HOOK_FLAG_USER_SHIFT (4)
1132 #define G_HOOK_DEFERRED_DESTROY ((GHookFreeFunc) 0x01)
1157 #define G_HOOK_ACTIVE(hook) ((((GHook*) hook)->flags & \
1158 G_HOOK_FLAG_ACTIVE) != 0)
1159 #define G_HOOK_IN_CALL(hook) ((((GHook*) hook)->flags & \
1160 G_HOOK_FLAG_IN_CALL) != 0)
1161 #define G_HOOK_IS_VALID(hook) (((GHook*) hook)->hook_id != 0 && \
1162 G_HOOK_ACTIVE (hook))
1163 #define G_HOOK_IS_UNLINKED(hook) (((GHook*) hook)->next == NULL && \
1164 ((GHook*) hook)->prev == NULL && \
1165 ((GHook*) hook)->hook_id == 0 && \
1166 ((GHook*) hook)->ref_count == 0)
1221 #define g_hook_append( hook_list, hook ) \
1222 g_hook_insert_before ((hook_list), NULL, (hook))
1269 const gchar *message,
1273 const gchar *format,
1282 #ifndef G_LOG_DOMAIN
1283 #define G_LOG_DOMAIN ((gchar*) 0)
1286 #define g_error(format, args...) g_log (G_LOG_DOMAIN, \
1287 G_LOG_LEVEL_ERROR, \
1289 #define g_message(format, args...) g_log (G_LOG_DOMAIN, \
1290 G_LOG_LEVEL_MESSAGE, \
1292 #define g_warning printf
1298 #define g_malloc(size) ((gpointer)malloc(size))
1299 #define g_malloc0(size) ((gpointer)calloc(size, 1))
1300 #define g_realloc(mem,size) ((gpointer)realloc(mem, size))
1301 #define g_free(mem) free(mem)
1311 #define G_STR_DELIMITERS "_-|> <."
1313 const gchar *delimiters,
1314 gchar new_delimiter);
1332 #define g_strstrip( string ) g_strchomp (g_strchug (string))
1431 if (mask & (1 << (
guint) nth_bit))
1434 while (nth_bit < 32);
1451 if (mask & (1 << (
guint) nth_bit))
1454 while (nth_bit > 0);
1464 register guint n_bits = 0;
1481 const gchar *
string);
1483 const gchar *
string);
1516 const gchar *format,
1528 #define g_array_append_val(a,v) pmidi_array_append_vals (a, &v, 1)
1529 #define g_array_prepend_val(a,v) g_array_prepend_vals (a, &v, 1)
1530 #define g_array_insert_val(a,i,v) g_array_insert_vals (a, i, &v, 1)
1531 #define g_array_index(a,t,i) (((t*) (a)->data) [(i)])
1535 guint element_size);
1560 #define g_ptr_array_index(array,index) (array->pdata)[index]
void(* GHFunc)(gpointer key, gpointer value, gpointer user_data)
Definition: glib.h:767
void g_hook_destroy_link(GHookList *hook_list, GHook *hook)
GString * g_string_assign(GString *lval, const gchar *rval)
void g_cache_key_foreach(GCache *cache, GHFunc func, gpointer user_data)
void g_ptr_array_set_size(GPtrArray *array, gint length)
void g_hash_table_destroy(GHashTable *hash_table)
void(* GHookMarshaller)(GHook *hook, gpointer data)
Definition: glib.h:777
GUTILS_C_VAR const guint glib_binary_age
Definition: glib.h:673
void g_hook_list_init(GHookList *hook_list, guint hook_size)
GNode * children
Definition: glib.h:1031
GArray * g_array_set_size(GArray *array, guint length)
GNode * g_node_find_child(GNode *node, GTraverseFlags flags, gpointer data)
gchar * g_strconcat(const gchar *string1,...)
gpointer pmidi_ptr_array_remove_index_fast(GPtrArray *array, guint index)
GSList * g_slist_remove(GSList *list, gpointer data)
gchar * g_strjoinv(const gchar *separator, gchar **str_array)
gint(* GSearchFunc)(gpointer key, gpointer data)
Definition: glib.h:793
GCache * g_cache_new(GCacheNewFunc value_new_func, GCacheDestroyFunc value_destroy_func, GCacheDupFunc key_dup_func, GCacheDestroyFunc key_destroy_func, GHashFunc hash_key_func, GHashFunc hash_value_func, GCompareFunc key_compare_func)
gint g_strcasecmp(const gchar *s1, const gchar *s2)
GByteArray * g_byte_array_append(GByteArray *array, const guint8 *data, guint len)
gpointer g_hash_table_lookup(GHashTable *hash_table, gconstpointer key)
const void * gconstpointer
Definition: glib.h:492
gboolean(* GHookCheckMarshaller)(GHook *hook, gpointer data)
Definition: glib.h:779
guint8 * data
Definition: glib.h:831
GList * next
Definition: glib.h:807
gboolean(* GHookCheckFunc)(gpointer data)
Definition: glib.h:782
gchar * g_strerror(gint errnum)
gchar * g_get_prgname(void)
@ G_HOOK_FLAG_ACTIVE
Definition: glib.h:1127
GList * g_list_alloc(void)
struct _GIOChannel GIOChannel
Definition: glib.h:707
@ G_HOOK_FLAG_IN_CALL
Definition: glib.h:1128
void(* GLogFunc)(const gchar *log_domain, GLogLevelFlags log_level, const gchar *message, gpointer user_data)
Definition: glib.h:785
void g_strdown(gchar *string)
unsigned short guint16
Definition: glib.h:74
@ G_HOOK_FLAG_MASK
Definition: glib.h:1129
GArray * g_array_insert_vals(GArray *array, guint index, gconstpointer data, guint len)
GList * g_list_insert(GList *list, gpointer data, gint position)
GString * g_string_new(const gchar *init)
gint g_snprintf(gchar *string, gulong n, gchar const *format,...) G_GNUC_PRINTF(3
void void g_string_sprintfa(GString *string, const gchar *format,...) G_GNUC_PRINTF(2
void g_cache_destroy(GCache *cache)
gint g_strncasecmp(const gchar *s1, const gchar *s2, guint n)
gint len
Definition: glib.h:820
gboolean(* GHookFindFunc)(GHook *hook, gpointer data)
Definition: glib.h:775
guint(* GHashFunc)(gconstpointer key)
Definition: glib.h:765
GList * g_list_append(GList *list, gpointer data)
guint len
Definition: glib.h:843
void g_strreverse(gchar *string)
GList * g_list_last(GList *list)
GByteArray * g_byte_array_new(void)
GTraverseType
Definition: glib.h:718
gpointer * pdata
Definition: glib.h:837
gint g_list_index(GList *list, gpointer data)
@ G_TRAVERSE_LEAFS
Definition: glib.h:711
gint g_slist_position(GSList *list, GSList *llink)
GList * g_list_nth(GList *list, guint n)
@ G_IN_ORDER
Definition: glib.h:719
gpointer func
Definition: glib.h:1153
void g_tree_destroy(GTree *tree)
unsigned char guint8
Definition: glib.h:72
gdouble g_strtod(const gchar *nptr, gchar **endptr)
gboolean g_node_is_ancestor(GNode *node, GNode *descendant)
gchar * g_get_home_dir(void)
GByteArray * g_byte_array_remove_index_fast(GByteArray *array, guint index)
GHook * prev
Definition: glib.h:1149
guint ref_count
Definition: glib.h:1150
int gint
Definition: glib.h:469
void g_list_push_allocator(GAllocator *allocator)
GSList * g_slist_reverse(GSList *list)
void g_log_remove_handler(const gchar *log_domain, guint handler_id)
gchar * g_strdup_printf(const gchar *format,...) G_GNUC_PRINTF(1
GList * g_list_concat(GList *list1, GList *list2)
GHook * g_hook_find_func_data(GHookList *hook_list, gboolean need_valids, gpointer func, gpointer data)
unsigned int guint32
Definition: glib.h:76
void g_tree_insert(GTree *tree, gpointer key, gpointer value)
void g_hook_list_invoke(GHookList *hook_list, gboolean may_recurse)
GNode * g_node_first_sibling(GNode *node)
GByteArray * g_byte_array_prepend(GByteArray *array, const guint8 *data, guint len)
gchar * g_path_skip_root(gchar *file_name)
GList * g_list_prepend(GList *list, gpointer data)
GLogLevelFlags g_log_set_fatal_mask(const gchar *log_domain, GLogLevelFlags fatal_mask)
void g_list_pop_allocator(void)
GNode * prev
Definition: glib.h:1029
gpointer g_memdup(gconstpointer mem, guint byte_size)
GList * g_list_sort(GList *list, GCompareFunc compare_func)
void g_byte_array_free(GByteArray *array, gboolean free_segment)
GList * g_list_find_custom(GList *list, gpointer data, GCompareFunc func)
gchar * g_strndup(const gchar *str, guint n)
struct _GStringChunk GStringChunk
Definition: glib.h:702
GNode * g_node_nth_child(GNode *node, guint n)
guint g_slist_length(GSList *list)
guint g_hash_table_size(GHashTable *hash_table)
gint g_slist_index(GSList *list, gpointer data)
gchar * g_get_real_name(void)
void g_string_chunk_free(GStringChunk *chunk)
#define G_GNUC_PRINTF(format_idx, arg_idx)
Definition: glib.h:262
gchar * g_strdup(const gchar *str)
GHook * g_hook_get(GHookList *hook_list, guint hook_id)
gint g_hook_compare_ids(GHook *new_hook, GHook *sibling)
gchar * g_strdelimit(gchar *string, const gchar *delimiters, gchar new_delimiter)
GString * g_string_sized_new(guint dfl_size)
guint g_parse_debug_string(const gchar *string, GDebugKey *keys, guint nkeys)
GArray * g_array_remove_index_fast(GArray *array, guint index)
GSList * g_slist_insert_sorted(GSList *list, gpointer data, GCompareFunc func)
@ G_LOG_FLAG_RECURSION
Definition: glib.h:735
gchar * g_get_tmp_dir(void)
gboolean(* GHRFunc)(gpointer key, gpointer value, gpointer user_data)
Definition: glib.h:770
const gchar * g_log_domain_glib
GSList * g_slist_find_custom(GSList *list, gpointer data, GCompareFunc func)
void(* GCacheDestroyFunc)(gpointer value)
Definition: glib.h:755
gchar * str
Definition: glib.h:819
gchar * g_strchomp(gchar *string)
GTraverseFlags
Definition: glib.h:710
gint gboolean
Definition: glib.h:470
void g_hook_list_invoke_check(GHookList *hook_list, gboolean may_recurse)
GUTILS_C_VAR const guint glib_interface_age
Definition: glib.h:672
GSList * next
Definition: glib.h:814
GNode * parent
Definition: glib.h:1030
void(* GFunc)(gpointer data, gpointer user_data)
Definition: glib.h:763
GString * g_string_truncate(GString *string, gint len)
void(* GNodeForeachFunc)(GNode *node, gpointer data)
Definition: glib.h:791
void g_hash_table_remove(GHashTable *hash_table, gconstpointer key)
gint g_node_child_position(GNode *node, GNode *child)
void g_cache_remove(GCache *cache, gpointer value)
void g_hash_table_thaw(GHashTable *hash_table)
gpointer g_tree_search(GTree *tree, GSearchFunc search_func, gpointer data)
void g_hook_ref(GHookList *hook_list, GHook *hook)
GNode * g_node_find(GNode *root, GTraverseType order, GTraverseFlags flags, gpointer data)
GSList * g_slist_last(GSList *list)
gchar * g_strnfill(guint length, gchar fill_char)
void * gpointer
Definition: glib.h:491
void pmidi_ptr_array_free(GPtrArray *array, gboolean free_seg)
union _GTokenValue GTokenValue
Definition: glib.h:706
GList * g_list_insert_sorted(GList *list, gpointer data, GCompareFunc func)
gpointer g_cache_insert(GCache *cache, gpointer key)
gint g_tree_height(GTree *tree)
guint is_setup
Definition: glib.h:1138
unsigned char guchar
Definition: glib.h:472
GUTILS_C_VAR const guint glib_major_version
Definition: glib.h:669
GDestroyNotify destroy
Definition: glib.h:1154
guint len
Definition: glib.h:832
void g_node_unlink(GNode *node)
GHook * next
Definition: glib.h:1148
void(* GHookFunc)(gpointer data)
Definition: glib.h:781
void g_log_default_handler(const gchar *log_domain, GLogLevelFlags log_level, const gchar *message, gpointer unused_data)
signed char gint8
Definition: glib.h:71
void g_hook_unref(GHookList *hook_list, GHook *hook)
guint g_node_max_height(GNode *root)
gchar * g_get_user_name(void)
GNode * g_node_last_child(GNode *node)
GHashTable * g_hash_table_new(GHashFunc hash_func, GCompareFunc key_compare_func)
void(* GDataForeachFunc)(GQuark key_id, gpointer data, gpointer user_data)
Definition: glib.h:760
struct _GMemChunk GMemChunk
Definition: glib.h:694
GString * g_string_up(GString *string)
void pmidi_ptr_array_add(GPtrArray *array, gpointer data)
gpointer data
Definition: glib.h:1027
struct _GRelation GRelation
Definition: glib.h:697
gint g_tree_nnodes(GTree *tree)
guint g_node_depth(GNode *node)
void g_slist_foreach(GSList *list, GFunc func, gpointer user_data)
guint hook_id
Definition: glib.h:1151
struct _GAllocator GAllocator
Definition: glib.h:683
GString * g_string_prepend(GString *string, const gchar *val)
void g_hook_free(GHookList *hook_list, GHook *hook)
GNode * next
Definition: glib.h:1028
gchar * g_basename(const gchar *file_name)
unsigned short gushort
Definition: glib.h:473
gpointer g_list_nth_data(GList *list, guint n)
GUTILS_C_VAR const guint glib_micro_version
Definition: glib.h:671
GList * g_list_remove_link(GList *list, GList *llink)
GHook * hooks
Definition: glib.h:1139
void(* GHookFreeFunc)(GHookList *hook_list, GHook *hook)
Definition: glib.h:783
void g_hash_table_foreach(GHashTable *hash_table, GHFunc func, gpointer user_data)
void void g_logv(const gchar *log_domain, GLogLevelFlags log_level, const gchar *format, va_list args)
gpointer(* GCacheDupFunc)(gpointer value)
Definition: glib.h:754
gboolean g_hash_table_lookup_extended(GHashTable *hash_table, gconstpointer lookup_key, gpointer *orig_key, gpointer *value)
void g_node_reverse_children(GNode *node)
GHook * g_hook_find(GHookList *hook_list, gboolean need_valids, GHookFindFunc func, gpointer data)
void g_tree_remove(GTree *tree, gpointer key)
gchar * g_string_chunk_insert_const(GStringChunk *chunk, const gchar *string)
gboolean g_hook_destroy(GHookList *hook_list, guint hook_id)
gchar gchar * g_strdup_vprintf(const gchar *format, va_list args)
GList * g_list_remove(GList *list, gpointer data)
GArray * g_array_prepend_vals(GArray *array, gconstpointer data, guint len)
unsigned long gulong
Definition: glib.h:474
gchar * g_string_chunk_insert(GStringChunk *chunk, const gchar *string)
void g_strfreev(gchar **str_array)
guint g_list_length(GList *list)
GTree * g_tree_new(GCompareFunc key_compare_func)
gint(* GCompareFunc)(gconstpointer a, gconstpointer b)
Definition: glib.h:756
void g_hook_prepend(GHookList *hook_list, GHook *hook)
gpointer data
Definition: glib.h:1147
double gdouble
Definition: glib.h:478
gpointer data
Definition: glib.h:806
void g_list_foreach(GList *list, GFunc func, gpointer user_data)
void g_node_push_allocator(GAllocator *allocator)
struct _GCompletion GCompletion
Definition: glib.h:687
GList * g_list_first(GList *list)
gint32 GTime
Definition: glib.h:498
gchar * g_strsignal(gint signum)
GHookFlagMask
Definition: glib.h:1126
@ G_LOG_LEVEL_CRITICAL
Definition: glib.h:740
GStringChunk * g_string_chunk_new(gint size)
void(* GScannerMsgFunc)(GScanner *scanner, gchar *message, gint error)
Definition: glib.h:795
GSList * g_slist_copy(GSList *list)
@ G_PRE_ORDER
Definition: glib.h:720
void g_hook_list_marshal(GHookList *hook_list, gboolean may_recurse, GHookMarshaller marshaller, gpointer data)
GSList * g_slist_nth(GSList *list, guint n)
guint g_log_set_handler(const gchar *log_domain, GLogLevelFlags log_levels, GLogFunc log_func, gpointer user_data)
GArray * g_array_remove_index(GArray *array, guint index)
GLogLevelFlags
Definition: glib.h:733
void g_hook_list_marshal_check(GHookList *hook_list, gboolean may_recurse, GHookCheckMarshaller marshaller, gpointer data)
gchar * g_strjoin(const gchar *separator,...)
GSList * g_slist_concat(GSList *list1, GSList *list2)
void g_hash_table_freeze(GHashTable *hash_table)
GMemChunk * hook_memchunk
Definition: glib.h:1140
gchar ** g_strsplit(const gchar *string, const gchar *delimiter, gint max_tokens)
@ G_LOG_LEVEL_DEBUG
Definition: glib.h:744
GSList * g_slist_remove_link(GSList *list, GSList *llink)
void g_slist_free(GSList *list)
GPtrArray * pmidi_ptr_array_new(void)
GSList * g_slist_sort(GSList *list, GCompareFunc compare_func)
gchar * g_dirname(const gchar *file_name)
GNode * g_node_insert_before(GNode *parent, GNode *sibling, GNode *node)
guint len
Definition: glib.h:826
GLogLevelFlags g_log_set_always_fatal(GLogLevelFlags fatal_mask)
#define G_INLINE_FUNC
Definition: glib.h:215
gchar * g_strescape(gchar *string)
@ G_TRAVERSE_ALL
Definition: glib.h:713
void pmidi_array_free(GArray *array, gboolean free_segment)
GString * g_string_erase(GString *string, gint pos, gint len)
gchar * key
Definition: glib.h:848
guint32 GQuark
Definition: glib.h:497
GString * g_string_down(GString *string)
GSList * g_slist_prepend(GSList *list, gpointer data)
struct _GData GData
Definition: glib.h:688
guint flags
Definition: glib.h:1152
guint32 gsize
Definition: glib.h:496
void g_node_pop_allocator(void)
void g_hash_table_insert(GHashTable *hash_table, gpointer key, gpointer value)
void g_mem_check(gpointer mem)
GNode * g_node_insert(GNode *parent, gint position, GNode *node)
@ G_LOG_LEVEL_MASK
Definition: glib.h:746
gboolean(* GNodeTraverseFunc)(GNode *node, gpointer data)
Definition: glib.h:789
GHook * g_hook_find_func(GHookList *hook_list, gboolean need_valids, gpointer func)
gint(* GTraverseFunc)(gpointer key, gpointer value, gpointer data)
Definition: glib.h:798
GHook * g_hook_alloc(GHookList *hook_list)
void g_cache_value_foreach(GCache *cache, GHFunc func, gpointer user_data)
gboolean g_ptr_array_remove(GPtrArray *array, gpointer data)
guint len
Definition: glib.h:838
void g_list_free_1(GList *list)
void g_hook_insert_before(GHookList *hook_list, GHook *sibling, GHook *hook)
GString * g_string_insert(GString *string, gint pos, const gchar *val)
GSList * g_slist_find(GSList *list, gpointer data)
struct _GTimer GTimer
Definition: glib.h:703
void g_hook_insert_sorted(GHookList *hook_list, GHook *hook, GHookCompareFunc func)
void(* GVoidFunc)(void)
Definition: glib.h:801
gpointer g_ptr_array_remove_index(GPtrArray *array, guint index)
unsigned int guint
Definition: glib.h:475
GNode * g_node_new(gpointer data)
gchar * g_get_current_dir(void)
gint g_node_child_index(GNode *node, gpointer data)
void g_node_destroy(GNode *root)
struct _GCache GCache
Definition: glib.h:686
@ G_LEVEL_ORDER
Definition: glib.h:722
GList * g_list_copy(GList *list)
struct _GScannerConfig GScannerConfig
Definition: glib.h:699
GString * g_string_prepend_c(GString *string, gchar c)
void g_list_free(GList *list)
GNode * g_node_last_sibling(GNode *node)
void g_slist_pop_allocator(void)
void g_string_sprintf(GString *string, const gchar *format,...) G_GNUC_PRINTF(2
short gshort
Definition: glib.h:467
gboolean g_ptr_array_remove_fast(GPtrArray *array, gpointer data)
guint g_node_n_nodes(GNode *root, GTraverseFlags flags)
gint g_list_position(GList *list, GList *llink)
@ G_TRAVERSE_MASK
Definition: glib.h:714
@ G_LOG_FLAG_FATAL
Definition: glib.h:736
gint(* GHookCompareFunc)(GHook *new_hook, GHook *sibling)
Definition: glib.h:773
guint value
Definition: glib.h:849
@ G_TRAVERSE_NON_LEAFS
Definition: glib.h:712
GNode * g_node_prepend(GNode *parent, GNode *node)
GByteArray * g_byte_array_set_size(GByteArray *array, guint length)
GList * g_list_reverse(GList *list)
void g_atexit(GVoidFunc func)
G_INLINE_FUNC gint g_bit_nth_lsf(guint32 mask, gint nth_bit)
gint gint g_vsnprintf(gchar *string, gulong n, gchar const *format, va_list args)
GHook * g_hook_find_data(GHookList *hook_list, gboolean need_valids, gpointer data)
void g_on_error_query(const gchar *prg_name)
char gchar
Definition: glib.h:466
gchar * g_strchug(gchar *string)
signed int gint32
Definition: glib.h:75
void g_hook_list_clear(GHookList *hook_list)
guint g_hash_table_foreach_remove(GHashTable *hash_table, GHRFunc func, gpointer user_data)
void g_string_free(GString *string, gint free_segment)
GByteArray * g_byte_array_remove_index(GByteArray *array, guint index)
void g_node_traverse(GNode *root, GTraverseType order, GTraverseFlags flags, gint max_depth, GNodeTraverseFunc func, gpointer data)
void g_node_children_foreach(GNode *node, GTraverseFlags flags, GNodeForeachFunc func, gpointer data)
G_INLINE_FUNC gint g_bit_nth_msf(guint32 mask, gint nth_bit)
@ G_LOG_LEVEL_MESSAGE
Definition: glib.h:742
G_INLINE_FUNC guint g_bit_storage(guint number)
gpointer g_slist_nth_data(GSList *list, guint n)
#define GUTILS_C_VAR
Definition: glib.h:666
GUTILS_C_VAR const guint glib_minor_version
Definition: glib.h:670
long glong
Definition: glib.h:468
GHook * g_hook_first_valid(GHookList *hook_list, gboolean may_be_in_call)
signed short gint16
Definition: glib.h:73
void g_set_prgname(const gchar *prgname)
GHookFreeFunc hook_destroy
Definition: glib.h:1142
GString * g_string_append_c(GString *string, gchar c)
gchar * data
Definition: glib.h:825
gboolean g_path_is_absolute(const gchar *file_name)
void g_slist_free_1(GSList *list)
@ G_LOG_LEVEL_WARNING
Definition: glib.h:741
GString * g_string_append(GString *string, const gchar *val)
GSList * g_slist_insert(GSList *list, gpointer data, gint position)
GSList * g_slist_append(GSList *list, gpointer data)
GSList * g_slist_alloc(void)
@ G_POST_ORDER
Definition: glib.h:721
GHook * g_hook_next_valid(GHookList *hook_list, GHook *hook, gboolean may_be_in_call)
gpointer g_tree_lookup(GTree *tree, gpointer key)
void(* GDestroyNotify)(gpointer data)
Definition: glib.h:759
void(* GFreeFunc)(gpointer data)
Definition: glib.h:766
GArray * pmidi_array_new(gboolean zero_terminated, gboolean clear, guint element_size)
guint g_printf_string_upper_bound(const gchar *format, va_list args)
void g_slist_push_allocator(GAllocator *allocator)
gint32 gssize
Definition: glib.h:495
@ G_LOG_LEVEL_INFO
Definition: glib.h:743
GArray * pmidi_array_append_vals(GArray *array, gconstpointer data, guint len)
void g_strup(gchar *string)
void g_tree_traverse(GTree *tree, GTraverseFunc traverse_func, GTraverseType traverse_type, gpointer data)
GList * g_list_find(GList *list, gpointer data)
guint g_node_n_children(GNode *node)
float gfloat
Definition: glib.h:477
void g_on_error_stack_trace(const gchar *prg_name)
GNode * g_node_get_root(GNode *node)
struct _GHashTable GHashTable
Definition: glib.h:690
GList * prev
Definition: glib.h:808
gpointer data
Definition: glib.h:813
GString * g_string_insert_c(GString *string, gint pos, gchar c)
struct _GScanner GScanner
Definition: glib.h:698
gpointer(* GCacheNewFunc)(gpointer key)
Definition: glib.h:753
void g_log(const gchar *log_domain, GLogLevelFlags log_level, const gchar *format,...) G_GNUC_PRINTF(3
guint seq_id
Definition: glib.h:1136
GHookFreeFunc hook_free
Definition: glib.h:1141
guint hook_size
Definition: glib.h:1137
@ G_LOG_LEVEL_ERROR
Definition: glib.h:739
#define const
Definition: zconf.h:124
gchar * g_getenv(const gchar *variable)
struct _GTree GTree
Definition: glib.h:704