1 /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*-
2 * gdl-combo-button.h
3 *
4 * Copyright (C) 2003 Jeroen Zwartepoorte
5 *
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
10 *
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
15 *
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 */
21 #ifndef _GDL_COMBO_BUTTON_H_
22 #define _GDL_COMBO_BUTTON_H_
24 #include <gdk-pixbuf/gdk-pixbuf.h>
25 #include <gtk/gtkhbox.h>
26 #include <gtk/gtkmenu.h>
28 G_BEGIN_DECLS
30 #define GDL_TYPE_COMBO_BUTTON (gdl_combo_button_get_type ())
31 #define GDL_COMBO_BUTTON(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GDL_TYPE_COMBO_BUTTON, GdlComboButton))
32 #define GDL_COMBO_BUTTON_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GDL_TYPE_COMBO_BUTTON, GdlComboButtonClass))
33 #define GDL_IS_COMBO_BUTTON(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GDL_TYPE_COMBO_BUTTON))
34 #define GDL_IS_COMBO_BUTTON_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((obj), GDL_TYPE_COMBO_BUTTON))
36 typedef struct _GdlComboButton GdlComboButton;
37 typedef struct _GdlComboButtonPrivate GdlComboButtonPrivate;
38 typedef struct _GdlComboButtonClass GdlComboButtonClass;
40 struct _GdlComboButton {
41 GtkHBox parent;
43 GdlComboButtonPrivate *priv;
44 };
46 struct _GdlComboButtonClass {
47 GtkHBoxClass parent_class;
49 /* Signals. */
50 void (* activate_default) (GdlComboButton *combo_button);
51 };
53 GType gdl_combo_button_get_type (void);
54 GtkWidget *gdl_combo_button_new (void);
56 void gdl_combo_button_set_icon (GdlComboButton *combo_button,
57 GdkPixbuf *pixbuf);
58 void gdl_combo_button_set_label (GdlComboButton *combo_button,
59 const gchar *label);
60 void gdl_combo_button_set_menu (GdlComboButton *combo_button,
61 GtkMenu *menu);
63 G_END_DECLS
65 #endif /* _GDL_COMBO_BUTTON_H_ */