BEAST/BSE - Better Audio System and Sound Engine  0.8.2
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
gxkglobals.hh
Go to the documentation of this file.
00001  // Licensed GNU LGPL v2.1 or later: http://www.gnu.org/licenses/lgpl.html
00002 #ifndef __GXK_GLOBALS_H__
00003 #define __GXK_GLOBALS_H__
00004 
00005 #include <sfi/glib-extra.hh>
00006 #include <gtk/gtk.h>
00007 
00008 G_BEGIN_DECLS
00009 
00010 /* --- i18n and gettext helpers --- */
00011 #ifdef GXK_COMPILATION
00012 #  define GXK_I18N_DOMAIN NULL
00013 #  define _(str)        dgettext (GXK_I18N_DOMAIN, str)
00014 #  define T_(str)       dgettext (GXK_I18N_DOMAIN, str)
00015 #  define N_(str)       (str)
00016 #endif
00017 
00018 
00019 /* --- macros --- */
00020 #define GXK_TOOLTIPS    (gxk_globals->tooltips)
00021 
00022 
00023 /* --- typedefs & structures --- */
00024 typedef void (*GxkFreeFunc) (gpointer data);
00025 typedef struct
00026 {
00027   GtkTooltips *tooltips;
00028 } GxkGlobals;
00029 
00030 
00031 /* --- spacing/padding --- */
00032 #define GXK_OUTER_BORDER        (5)     /* outer dialog border-width */
00033 #define GXK_INNER_SPACING       (3)     /* spacing/padding between h/v boxes */
00034 #define GXK_BUTTON_PADDING      (3)     /* padding between adjacent buttons */
00035 
00036 
00037 /* --- convenience --- */
00038 gulong  gxk_nullify_in_object (gpointer object,
00039                                gpointer location);
00040 
00041 
00042 /* --- variables --- */
00043 extern const GxkGlobals* gxk_globals;
00044 
00045 
00046 /* --- functions --- */
00047 void    gxk_init        (void);
00048 
00049 
00050 /* --- internal --- */
00051 void    gxk_init_utils          (void);
00052 void    gxk_init_params         (void);
00053 void    gxk_init_stock          (void);
00054 void    gxk_init_actions        (void);
00055 void    gxk_init_assortments    (void);
00056 void    gxk_init_radget_types   (void);
00057 
00058 
00059 G_END_DECLS
00060 
00061 // == Flags Enumeration Operators in C++ ==
00062 #ifdef __cplusplus
00063 constexpr GdkEventMask  operator&  (GdkEventMask  s1, GdkEventMask s2) { return GdkEventMask (s1 & (long long unsigned) s2); }
00064 inline    GdkEventMask& operator&= (GdkEventMask &s1, GdkEventMask s2) { s1 = s1 & s2; return s1; }
00065 constexpr GdkEventMask  operator|  (GdkEventMask  s1, GdkEventMask s2) { return GdkEventMask (s1 | (long long unsigned) s2); }
00066 inline    GdkEventMask& operator|= (GdkEventMask &s1, GdkEventMask s2) { s1 = s1 | s2; return s1; }
00067 constexpr GdkEventMask  operator~  (GdkEventMask  s1)                 { return GdkEventMask (~(long long unsigned) s1); }
00068 constexpr GdkModifierType  operator&  (GdkModifierType  s1, GdkModifierType s2) { return GdkModifierType (s1 & (long long unsigned) s2); }
00069 inline    GdkModifierType& operator&= (GdkModifierType &s1, GdkModifierType s2) { s1 = s1 & s2; return s1; }
00070 constexpr GdkModifierType  operator|  (GdkModifierType  s1, GdkModifierType s2) { return GdkModifierType (s1 | (long long unsigned) s2); }
00071 inline    GdkModifierType& operator|= (GdkModifierType &s1, GdkModifierType s2) { s1 = s1 | s2; return s1; }
00072 constexpr GdkModifierType  operator~  (GdkModifierType  s1)                 { return GdkModifierType (~(long long unsigned) s1); }
00073 constexpr GdkWindowHints  operator&  (GdkWindowHints  s1, GdkWindowHints s2) { return GdkWindowHints (s1 & (long long unsigned) s2); }
00074 inline    GdkWindowHints& operator&= (GdkWindowHints &s1, GdkWindowHints s2) { s1 = s1 & s2; return s1; }
00075 constexpr GdkWindowHints  operator|  (GdkWindowHints  s1, GdkWindowHints s2) { return GdkWindowHints (s1 | (long long unsigned) s2); }
00076 inline    GdkWindowHints& operator|= (GdkWindowHints &s1, GdkWindowHints s2) { s1 = s1 | s2; return s1; }
00077 constexpr GdkWindowHints  operator~  (GdkWindowHints  s1)                 { return GdkWindowHints (~(long long unsigned) s1); }
00078 constexpr GtkAttachOptions  operator&  (GtkAttachOptions  s1, GtkAttachOptions s2) { return GtkAttachOptions (s1 & (long long unsigned) s2); }
00079 inline    GtkAttachOptions& operator&= (GtkAttachOptions &s1, GtkAttachOptions s2) { s1 = s1 & s2; return s1; }
00080 constexpr GtkAttachOptions  operator|  (GtkAttachOptions  s1, GtkAttachOptions s2) { return GtkAttachOptions (s1 | (long long unsigned) s2); }
00081 inline    GtkAttachOptions& operator|= (GtkAttachOptions &s1, GtkAttachOptions s2) { s1 = s1 | s2; return s1; }
00082 constexpr GtkAttachOptions  operator~  (GtkAttachOptions  s1)                 { return GtkAttachOptions (~(long long unsigned) s1); }
00083 #endif // __cplusplus
00084 #endif /* __GXK_GLOBALS_H__ */
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines