BEAST - Free Software Audio Synthesizer and Tracker  0.9.2
gxkstatusbar.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 __GXK_STATUS_BAR_H__
3 #define __GXK_STATUS_BAR_H__
4 
5 #include <gxk/gxkutils.hh>
6 
7 G_BEGIN_DECLS
8 
9 /* --- status percentages --- */
10 #define GXK_STATUS_PROGRESS (+200.0)
11 #define GXK_STATUS_DONE (+100.0)
12 #define GXK_STATUS_IDLE_HINT (-0.4)
13 #define GXK_STATUS_IDLE (-0.5)
14 #define GXK_STATUS_WAIT (-1.0)
15 #define GXK_STATUS_ERROR (-2.0)
16 /* 0..+100 is normal progression percentage */
17 
18 
19 /* --- auxillary structure --- */
20 typedef struct
21 {
22  GtkWidget *sbar;
23  GtkProgressBar *pbar;
24  GtkProgress *prog;
25  GtkLabel *message;
26  GtkLabel *status;
27  guint is_idle : 1;
28  guint timer_id;
29 } GxkStatusBar;
30 
31 
32 /* --- prototypes --- */
33 GtkWidget* gxk_status_bar_create (void);
34 void gxk_status_enable_error_bell (gboolean enable_error_bell);
35 void gxk_status_set (gfloat percentage,
36  const gchar *message,
37  const gchar *status_msg);
38 #define gxk_status_printf(percentage, status_msg, ...) gxk_status_set (percentage, status_msg, Rapicorn::string_format (__VA_ARGS__).c_str())
39 void gxk_status_clear (void);
40 void gxk_status_window_push (gpointer widget);
41 void gxk_status_window_pop (void);
42 void gxk_status_push_progress_window (gpointer widget);
43 void gxk_status_pop_progress_window (void);
44 
45 
46 G_END_DECLS
47 
48 #endif /* __GXK_STATUS_BAR_H__ */
void gxk_status_window_push(gpointer widget)
Definition: gxkstatusbar.cc:276
GtkWidget * gxk_status_bar_create(void)
Definition: gxkstatusbar.cc:64
Definition: gxkstatusbar.hh:20
void gxk_status_window_pop(void)
Pop the most recently pushed window from the status bar window stack.
Definition: gxkstatusbar.cc:291
void gxk_status_set(gfloat percentage, const gchar *message, const gchar *status_msg)
Definition: gxkstatusbar.cc:259
void gxk_status_clear(void)
Clear the current status bar.
Definition: gxkstatusbar.cc:155