2 * Copyright (C) 2003, 2004 Marco Pesenti Gritti
3 * Copyright (C) 2003, 2004, 2005 Christian Persch
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2, or (at your option)
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
22 #ifndef EGG_EDITABLE_TOOLBAR_H
23 #define EGG_EDITABLE_TOOLBAR_H
25 #include "egg-toolbars-model.h"
31 #define EGG_TYPE_EDITABLE_TOOLBAR (egg_editable_toolbar_get_type ())
32 #define EGG_EDITABLE_TOOLBAR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), EGG_TYPE_EDITABLE_TOOLBAR, EggEditableToolbar))
33 #define EGG_EDITABLE_TOOLBAR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), EGG_TYPE_EDITABLE_TOOLBAR, EggEditableToolbarClass))
34 #define EGG_IS_EDITABLE_TOOLBAR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), EGG_TYPE_EDITABLE_TOOLBAR))
35 #define EGG_IS_EDITABLE_TOOLBAR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), EGG_TYPE_EDITABLE_TOOLBAR))
36 #define EGG_EDITABLE_TOOLBAR_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), EGG_TYPE_EDITABLE_TOOLBAR, EggEditableToolbarClass))
38 typedef struct _EggEditableToolbar EggEditableToolbar;
39 typedef struct _EggEditableToolbarPrivate EggEditableToolbarPrivate;
40 typedef struct _EggEditableToolbarClass EggEditableToolbarClass;
42 struct _EggEditableToolbar
44 GtkVBox parent_object;
47 EggEditableToolbarPrivate *priv;
50 struct _EggEditableToolbarClass
52 GtkVBoxClass parent_class;
54 void (* action_request) (EggEditableToolbar *etoolbar,
55 const char *action_name);
58 GType egg_editable_toolbar_get_type (void);
59 GtkWidget *egg_editable_toolbar_new (GtkUIManager *manager,
60 const char *visibility_path);
61 GtkWidget *egg_editable_toolbar_new_with_model (GtkUIManager *manager,
62 EggToolbarsModel *model,
63 const char *visibility_path);
64 void egg_editable_toolbar_set_model (EggEditableToolbar *etoolbar,
65 EggToolbarsModel *model);
66 EggToolbarsModel *egg_editable_toolbar_get_model (EggEditableToolbar *etoolbar);
67 GtkUIManager *egg_editable_toolbar_get_manager (EggEditableToolbar *etoolbar);
68 void egg_editable_toolbar_set_edit_mode (EggEditableToolbar *etoolbar,
70 gboolean egg_editable_toolbar_get_edit_mode (EggEditableToolbar *etoolbar);
71 void egg_editable_toolbar_show (EggEditableToolbar *etoolbar,
73 void egg_editable_toolbar_hide (EggEditableToolbar *etoolbar,
75 void egg_editable_toolbar_set_fixed (EggEditableToolbar *etoolbar,
76 GtkToolbar *fixed_toolbar);
78 GtkWidget * egg_editable_toolbar_get_selected (EggEditableToolbar *etoolbar);
79 void egg_editable_toolbar_set_selected (EggEditableToolbar *etoolbar,
82 void egg_editable_toolbar_add_visibility (EggEditableToolbar *etoolbar,
85 /* Private Functions */
87 GtkWidget *_egg_editable_toolbar_new_separator_image (void);