]> www.fi.muni.cz Git - evince.git/blob - cut-n-paste/evinfobar/evinfobar.h
Bump GTK+ requirements to 2.20.0
[evince.git] / cut-n-paste / evinfobar / evinfobar.h
1 /*
2  * gtkinfobar.h
3  * This file is part of GTK+
4  *
5  * Copyright (C) 2005 - Paolo Maggi
6  *
7  * This library is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU Lesser General Public
9  * License as published by the Free Software Foundation; either
10  * version 2 of the License, or (at your option) any later version.
11  *
12  * This library is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
15  * Lesser General Public License for more details.
16  *
17  * You should have received a copy of the GNU Lesser General Public
18  * License along with this library; if not, write to the
19  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
20  * Boston, MA 02111-1307, USA.
21  */
22
23 /*
24  * Modified by the gedit Team, 2005. See the gedit AUTHORS file for a
25  * list of people on the gedit Team.
26  * See the gedit ChangeLog files for a list of changes.
27  *
28  * Modified by the GTK+ Team, 2008-2009.
29  */
30
31 #ifndef __EV_INFO_BAR_H__
32 #define __EV_INFO_BAR_H__
33
34 #include <gtk/gtk.h>
35
36 G_BEGIN_DECLS
37
38 /*
39  * Type checking and casting macros
40  */
41 #define EV_TYPE_INFO_BAR              (ev_info_bar_get_type())
42 #define EV_INFO_BAR(obj)              (G_TYPE_CHECK_INSTANCE_CAST((obj), EV_TYPE_INFO_BAR, EvInfoBar))
43 #define EV_INFO_BAR_CLASS(klass)      (G_TYPE_CHECK_CLASS_CAST((klass), EV_TYPE_INFO_BAR, EvInfoBarClass))
44 #define EV_IS_INFO_BAR(obj)           (G_TYPE_CHECK_INSTANCE_TYPE((obj), EV_TYPE_INFO_BAR))
45 #define EV_IS_INFO_BAR_CLASS(klass)   (G_TYPE_CHECK_CLASS_TYPE ((klass), EV_TYPE_INFO_BAR))
46 #define EV_INFO_BAR_GET_CLASS(obj)    (G_TYPE_INSTANCE_GET_CLASS((obj), EV_TYPE_INFO_BAR, EvInfoBarClass))
47
48
49 typedef struct _EvInfoBarPrivate EvInfoBarPrivate;
50 typedef struct _EvInfoBarClass EvInfoBarClass;
51 typedef struct _EvInfoBar EvInfoBar;
52
53
54 struct _EvInfoBar
55 {
56   GtkHBox parent;
57
58   /*< private > */
59   EvInfoBarPrivate *priv;
60 };
61
62
63 struct _EvInfoBarClass
64 {
65   GtkHBoxClass parent_class;
66
67   /* Signals */
68   void (* response) (EvInfoBar *info_bar, gint response_id);
69
70   /* Keybinding signals */
71   void (* close)    (EvInfoBar *info_bar);
72
73   /* Padding for future expansion */
74   void (*_gtk_reserved1) (void);
75   void (*_gtk_reserved2) (void);
76   void (*_gtk_reserved3) (void);
77   void (*_gtk_reserved4) (void);
78   void (*_gtk_reserved5) (void);
79   void (*_gtk_reserved6) (void);
80 };
81
82 GType          ev_info_bar_get_type               (void) G_GNUC_CONST;
83 GtkWidget     *ev_info_bar_new                    (void);
84
85 GtkWidget     *ev_info_bar_new_with_buttons       (const gchar    *first_button_text,
86                                                     ...);
87
88 GtkWidget     *ev_info_bar_get_action_area        (EvInfoBar     *info_bar);
89 GtkWidget     *ev_info_bar_get_content_area       (EvInfoBar     *info_bar);
90 void           ev_info_bar_add_action_widget      (EvInfoBar     *info_bar,
91                                                    GtkWidget      *child,
92                                                    gint            response_id);
93 GtkWidget     *ev_info_bar_add_button             (EvInfoBar     *info_bar,
94                                                    const gchar    *button_text,
95                                                    gint            response_id);
96 void           ev_info_bar_add_buttons            (EvInfoBar     *info_bar,
97                                                    const gchar    *first_button_text,
98                                                    ...);
99 void           ev_info_bar_set_response_sensitive (EvInfoBar     *info_bar,
100                                                    gint            response_id,
101                                                    gboolean        setting);
102 void           ev_info_bar_set_default_response   (EvInfoBar     *info_bar,
103                                                    gint            response_id);
104
105 /* Emit response signal */
106 void           ev_info_bar_response               (EvInfoBar     *info_bar,
107                                                    gint            response_id);
108
109 void           ev_info_bar_set_message_type       (EvInfoBar     *info_bar,
110                                                    GtkMessageType  message_type);
111 GtkMessageType ev_info_bar_get_message_type       (EvInfoBar     *info_bar);
112
113 G_END_DECLS
114
115 #endif  /* __EV_INFO_BAR_H__  */