1 | /* Gnome panel: a border widget |
---|
2 | * (C) 1999 the Free Software Foundation |
---|
3 | * |
---|
4 | * Authors: Jacob Berkman |
---|
5 | * George Lebl |
---|
6 | */ |
---|
7 | |
---|
8 | #ifndef BORDER_WIDGET_H |
---|
9 | #define BORDER_WIDGET_H |
---|
10 | |
---|
11 | #include "basep-widget.h" |
---|
12 | |
---|
13 | G_BEGIN_DECLS |
---|
14 | |
---|
15 | #define BORDER_TYPE_POS (border_pos_get_type ()) |
---|
16 | #define BORDER_POS(object) (G_TYPE_CHECK_INSTANCE_CAST ((object), BORDER_TYPE_POS, BorderPos)) |
---|
17 | #define BORDER_POS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), BORDER_TYPE_POS, BorderPosClass)) |
---|
18 | #define BORDER_IS_POS(object) (G_TYPE_CHECK_INSTANCE_TYPE ((object), BORDER_TYPE_POS)) |
---|
19 | #define BORDER_IS_POS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), BORDER_TYPE_POS)) |
---|
20 | |
---|
21 | #define BORDER_TYPE_WIDGET (BASEP_TYPE_WIDGET) |
---|
22 | #define BORDER_WIDGET(object) (BASEP_WIDGET(object)) |
---|
23 | #define BORDER_WIDGET_CLASS(klass) (BASEP_WIDGET_CLASS(klass)) |
---|
24 | #define BORDER_IS_WIDGET(object) (BASEP_IS_WIDGET(object) && BORDER_IS_POS( BASEP_WIDGET(object)->pos )) |
---|
25 | /* this is not reliable... */ |
---|
26 | #define BORDER_IS_WIDGET_CLASS(klass) (BASEP_IS_WIDGET_CLASS (klass)) |
---|
27 | |
---|
28 | typedef BasePWidget BorderWidget; |
---|
29 | typedef BasePWidgetClass BorderWidgetClass; |
---|
30 | |
---|
31 | typedef struct _BorderPos BorderPos; |
---|
32 | typedef struct _BorderPosClass BorderPosClass; |
---|
33 | |
---|
34 | struct _BorderPos { |
---|
35 | BasePPos pos; |
---|
36 | BorderEdge edge; |
---|
37 | }; |
---|
38 | |
---|
39 | struct _BorderPosClass { |
---|
40 | BasePPosClass parent_class; |
---|
41 | |
---|
42 | /* signals */ |
---|
43 | void (*edge_change) (BorderPos *border, |
---|
44 | BorderEdge edge); |
---|
45 | |
---|
46 | /* virtual funcs */ |
---|
47 | #if 0 |
---|
48 | void (*set_initial_pos) (BorderWidget *border); |
---|
49 | |
---|
50 | void (*save_settings) (BorderWidget *border); |
---|
51 | #endif |
---|
52 | }; |
---|
53 | |
---|
54 | GType border_pos_get_type (void) G_GNUC_CONST; |
---|
55 | |
---|
56 | GtkWidget *border_widget_construct (const char *panel_id, |
---|
57 | BorderWidget *border, |
---|
58 | int screen, |
---|
59 | int monitor, |
---|
60 | BorderEdge edge, |
---|
61 | gboolean packed, |
---|
62 | gboolean reverse_arrows, |
---|
63 | int sz, |
---|
64 | BasePMode mode, |
---|
65 | BasePState state, |
---|
66 | gboolean hidebuttons_enabled, |
---|
67 | gboolean hidebutton_pixmaps_enabled, |
---|
68 | PanelBackgroundType back_type, |
---|
69 | const char *back_pixmap, |
---|
70 | gboolean fit_pixmap_bg, |
---|
71 | gboolean stretch_pixmap_bg, |
---|
72 | gboolean rotate_pixmap_bg, |
---|
73 | PanelColor *back_color); |
---|
74 | |
---|
75 | void border_widget_change_params (BorderWidget *border, |
---|
76 | int screen, |
---|
77 | int monitor, |
---|
78 | BorderEdge edge, |
---|
79 | int sz, |
---|
80 | BasePMode mode, |
---|
81 | BasePState state, |
---|
82 | gboolean hidebuttons_enabled, |
---|
83 | gboolean hidebutton_pixmaps_enabled, |
---|
84 | PanelBackgroundType back_type, |
---|
85 | char *pixmap_name, |
---|
86 | gboolean fit_pixmap_bg, |
---|
87 | gboolean stretch_pixmap_bg, |
---|
88 | gboolean rotate_pixmap_bg, |
---|
89 | PanelColor *back_color); |
---|
90 | |
---|
91 | |
---|
92 | void border_widget_change_edge (BorderWidget *border, BorderEdge edge); |
---|
93 | |
---|
94 | G_END_DECLS |
---|
95 | #endif |
---|