BEAST - Free Software Audio Synthesizer and Tracker  0.9.2
bstdefs.hh
Go to the documentation of this file.
1  // Licensed GNU LGPL v2.1 or later: http://www.gnu.org/licenses/lgpl.html
2 #ifndef __BST_DEFS_H__
3 #define __BST_DEFS_H__
4 #include <gxk/gxk.hh>
5 #include <libintl.h>
6 #include "bstzoomedwindow.hh"
7 #include "bse/bse.hh"
8 
9 G_BEGIN_DECLS
10 
11 /* --- generic constants --- */
12 typedef enum {
13  BST_QUANTIZE_NONE = 0,
14  BST_QUANTIZE_NOTE_1 = 1,
15  BST_QUANTIZE_NOTE_2 = 2,
16  BST_QUANTIZE_NOTE_4 = 4,
17  BST_QUANTIZE_NOTE_8 = 8,
18  BST_QUANTIZE_NOTE_16 = 16,
19  BST_QUANTIZE_NOTE_32 = 32,
20  BST_QUANTIZE_NOTE_64 = 64,
21  BST_QUANTIZE_NOTE_128 = 128,
22  BST_QUANTIZE_TACT = 65535
23 } BstQuantizationType;
24 
25 typedef struct _BstKeyBinding BstKeyBinding;
26 
27 /* choose IDs that are unlikely to clash with category IDs */
28 #define BST_COMMON_ROLL_TOOL_FIRST (G_MAXINT - 100000)
29 
30 typedef enum /*< skip >*/
31 {
32  BST_COMMON_ROLL_TOOL_NONE,
33  BST_COMMON_ROLL_TOOL_INSERT = BST_COMMON_ROLL_TOOL_FIRST,
34  BST_COMMON_ROLL_TOOL_RESIZE,
35  BST_COMMON_ROLL_TOOL_LINK,
36  BST_COMMON_ROLL_TOOL_RENAME,
37  BST_COMMON_ROLL_TOOL_ALIGN,
38  BST_COMMON_ROLL_TOOL_MOVE,
39  BST_COMMON_ROLL_TOOL_DELETE,
40  BST_COMMON_ROLL_TOOL_SELECT,
41  BST_COMMON_ROLL_TOOL_VSELECT,
42  BST_COMMON_ROLL_TOOL_EDITOR,
43  BST_COMMON_ROLL_TOOL_MOVE_TICK_POINTER,
44  BST_COMMON_ROLL_TOOL_MOVE_TICK_LEFT,
45  BST_COMMON_ROLL_TOOL_MOVE_TICK_RIGHT,
46  BST_COMMON_ROLL_TOOL_LAST
47 } BstCommonRollTool;
48 
49 /* --- constants & defines --- */
50 #define BST_TAG_DIAMETER (20)
51 #define BST_STRDUP_RC_FILE() (g_strconcat (g_get_home_dir (), "/.beast/beastrc", NULL))
52 #define BST_STRDUP_SKIN_PATH() (g_strconcat ("~/.beast/skins/:~/.beast/skins/*/:", \
53  bse_installpath (BSE_INSTALLPATH_PKGDATADIR_SKINS).c_str(), NULL))
54 
55 /* --- configuration candidates --- */
56 /* mouse button numbers and masks for drag operations */
57 #define BST_DRAG_BUTTON_COPY (1)
58 #define BST_DRAG_BUTTON_COPY_MASK (GDK_BUTTON1_MASK)
59 #define BST_DRAG_BUTTON_MOVE (2)
60 #define BST_DRAG_BUTTON_MOVE_MASK (GDK_BUTTON2_MASK)
61 #define BST_DRAG_BUTTON_CONTEXT (3) /* delete, clone, linkdup */
62 
63 /* --- miscellaneous --- */
64 #define BST_DVL_HINTS (bst_developer_hints != FALSE)
65 #define BST_DBG_EXT (bst_debug_extensions != FALSE)
66 #define BST_MAIN_LOOP_QUIT() do { bst_main_loop_running = FALSE; } while (0)
67 #define GNOME_CANVAS_NOTIFY(object) G_STMT_START { \
68  if (GTK_IS_OBJECT (object)) \
69  g_signal_emit_by_name (object, "notify::generic-change", NULL); \
70 } G_STMT_END
71 
72 /* --- i18n and gettext helpers --- */
73 #define BEAST_GETTEXT_DOMAIN (NULL)
74 #define _(str) dgettext (BEAST_GETTEXT_DOMAIN, str)
75 #define N_(str) (str)
76 
77 /* --- internal stuff --- */
78 void beast_show_about_box (void);
79 void bst_main_loop_wakeup ();
80 extern gboolean bst_developer_hints;
81 extern gboolean bst_debug_extensions;
82 extern gboolean bst_main_loop_running;
83 
84 G_END_DECLS
85 
86 #endif /* __BST_DEFS_H__ */
Definition: bstkeybindings.hh:35
void bst_main_loop_wakeup()
wake up the main context used by the Beast main event looop.
Definition: bstmain.cc:429