2 * Copyright (C) 2003-2004 Marco Pesenti Gritti
3 * Copyright (C) 2004 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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
22 #ifndef EGG_EDITABLE_TOOLBAR_H
23 #define EGG_EDITABLE_TOOLBAR_H
25 #include "egg-toolbars-model.h"
27 #include <gtk/gtkuimanager.h>
28 #include <gtk/gtkselection.h>
29 #include <gtk/gtkvbox.h>
30 #include <gtk/gtktoolitem.h>
31 #include <gtk/gtktoolbar.h>
35 typedef struct EggEditableToolbarClass EggEditableToolbarClass;
37 #define EGG_TYPE_EDITABLE_TOOLBAR (egg_editable_toolbar_get_type ())
38 #define EGG_EDITABLE_TOOLBAR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), EGG_TYPE_EDITABLE_TOOLBAR, EggEditableToolbar))
39 #define EGG_EDITABLE_TOOLBAR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), EGG_TYPE_EDITABLE_TOOLBAR, EggEditableToolbarClass))
40 #define EGG_IS_EDITABLE_TOOLBAR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), EGG_TYPE_EDITABLE_TOOLBAR))
41 #define EGG_IS_EDITABLE_TOOLBAR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), EGG_TYPE_EDITABLE_TOOLBAR))
42 #define EGG_EDITABLE_TOOLBAR_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), EGG_TYPE_EDITABLE_TOOLBAR, EggEditableToolbarClass))
45 typedef struct EggEditableToolbar EggEditableToolbar;
46 typedef struct EggEditableToolbarPrivate EggEditableToolbarPrivate;
48 struct EggEditableToolbar
50 GtkVBox parent_object;
53 EggEditableToolbarPrivate *priv;
56 struct EggEditableToolbarClass
58 GtkVBoxClass parent_class;
60 void (* action_request) (EggEditableToolbar *etoolbar,
61 const char *action_name);
64 GType egg_editable_toolbar_get_type (void);
65 GtkWidget *egg_editable_toolbar_new (GtkUIManager *manager);
66 GtkWidget *egg_editable_toolbar_new_with_model (GtkUIManager *manager,
67 EggToolbarsModel *model);
68 void egg_editable_toolbar_set_model (EggEditableToolbar *etoolbar,
69 EggToolbarsModel *model);
70 EggToolbarsModel *egg_editable_toolbar_get_model (EggEditableToolbar *etoolbar);
71 void egg_editable_toolbar_set_edit_mode (EggEditableToolbar *etoolbar,
73 gboolean egg_editable_toolbar_get_edit_mode (EggEditableToolbar *etoolbar);
74 void egg_editable_toolbar_show (EggEditableToolbar *etoolbar,
76 void egg_editable_toolbar_hide (EggEditableToolbar *etoolbar,
78 void egg_editable_toolbar_set_drag_dest (EggEditableToolbar *etoolbar,
79 const GtkTargetEntry *targets,
81 const char *toolbar_name);
82 void egg_editable_toolbar_set_fixed (EggEditableToolbar *etoolbar,
86 /* Private Functions */
88 GtkWidget *_egg_editable_toolbar_new_separator_image (void);