From 88055228d2cd8780d281eb31bf688170c23254ce Mon Sep 17 00:00:00 2001 From: Brendan Taylor Date: Sat, 2 Jul 2011 10:55:29 +0000 Subject: the status bar is now a custom gtk widget it gives the left side of the status bar as much space as it needs (but importantly, no more than the size of the window. this should put the window resize bug to rest for good... --- src/status-bar.h | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 src/status-bar.h (limited to 'src/status-bar.h') diff --git a/src/status-bar.h b/src/status-bar.h new file mode 100644 index 0000000..e972701 --- /dev/null +++ b/src/status-bar.h @@ -0,0 +1,36 @@ +#ifndef __UZBL_STATUS_BAR_H__ +#define __UZBL_STATUS_BAR_H__ + +#include + +#define UZBL_TYPE_STATUS_BAR (uzbl_status_bar_get_type ()) +#define UZBL_STATUS_BAR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), UZBL_TYPE_STATUS_BAR, UzblStatusBar)) +#define UZBL_STATUS_BAR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), UZBL_TYPE_STATUS_BAR, UZblStatusBarClass)) +#define UZBL_IS_STATUS_BAR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), UZBL_TYPE_STATUS_BAR)) +#define UZBL_IS_STATUS_BAR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), UZBL_TYPE_STATUS_BAR)) +#define UZBL_STATUS_BAR_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), UZBL_TYPE_STATUS_BAR, UzblStatusBarClass)) + +typedef struct _UzblStatusBar UzblStatusBar; +typedef struct _UzblStatusBarClass UzblStatusBarClass; + +struct _UzblStatusBar { + GtkHBox hbox; + + GtkWidget *left_label; + GtkWidget *right_label; +}; + +struct _UzblStatusBarClass { + GtkHBoxClass parent_class; +}; + +GType uzbl_status_bar_get_type (void) G_GNUC_CONST; +GtkWidget * uzbl_status_bar_new (); + +void +uzbl_status_bar_update_left(GtkWidget *widget, const gchar *format); + +void +uzbl_status_bar_update_right(GtkWidget *widget, const gchar *format); + +#endif -- cgit v1.2.3