Ardour  9.0-pre0-582-g084a23a80d
gtkbuilder.h
Go to the documentation of this file.
1 /* GTK - The GIMP Toolkit
2  * Copyright (C) 2006-2007 Async Open Source,
3  * Johan Dahlin <jdahlin@async.com.br>
4  *
5  * This library is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Library General Public
7  * License as published by the Free Software Foundation; either
8  * version 2 of the License, or (at your option) any later version.
9  *
10  * This library 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 GNU
13  * Library General Public License for more details.
14  *
15  * You should have received a copy of the GNU Library General Public
16  * License along with this library; if not, write to the
17  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18  * Boston, MA 02111-1307, USA.
19  */
20 
21 #ifndef __GTK_BUILDER_H__
22 #define __GTK_BUILDER_H__
23 
24 #if defined(GTK_DISABLE_SINGLE_INCLUDES) && !defined (__GTK_H_INSIDE__) && !defined (GTK_COMPILATION)
25 #error "Only <gtk/gtk.h> can be included directly."
26 #endif
27 
28 #include <gdkconfig.h>
29 #include <glib-object.h>
30 
31 G_BEGIN_DECLS
32 
33 #define GTK_TYPE_BUILDER (gtk_builder_get_type ())
34 #define GTK_BUILDER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_TYPE_BUILDER, GtkBuilder))
35 #define GTK_BUILDER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GTK_TYPE_BUILDER, GtkBuilderClass))
36 #define GTK_IS_BUILDER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GTK_TYPE_BUILDER))
37 #define GTK_IS_BUILDER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GTK_TYPE_BUILDER))
38 #define GTK_BUILDER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GTK_TYPE_BUILDER, GtkBuilderClass))
39 
40 #define GTK_BUILDER_ERROR (gtk_builder_error_quark ())
41 
42 typedef struct _GtkBuilder GtkBuilder;
43 typedef struct _GtkBuilderClass GtkBuilderClass;
44 typedef struct _GtkBuilderPrivate GtkBuilderPrivate;
45 
46 typedef enum
47 {
58 
60 
62 {
63  GObject parent_instance;
64 
66 };
67 
69 {
70  GObjectClass parent_class;
71 
72  GType (* get_type_from_name) (GtkBuilder *builder,
73  const char *type_name);
74 
75  /* Padding for future expansion */
76  void (*_gtk_reserved1) (void);
77  void (*_gtk_reserved2) (void);
78  void (*_gtk_reserved3) (void);
79  void (*_gtk_reserved4) (void);
80  void (*_gtk_reserved5) (void);
81  void (*_gtk_reserved6) (void);
82  void (*_gtk_reserved7) (void);
83  void (*_gtk_reserved8) (void);
84 };
85 
86 typedef void (*GtkBuilderConnectFunc) (GtkBuilder *builder,
87  GObject *object,
88  const gchar *signal_name,
89  const gchar *handler_name,
90  GObject *connect_object,
91  GConnectFlags flags,
92  gpointer user_data);
93 
94 GType gtk_builder_get_type (void) G_GNUC_CONST;
96 
98  const gchar *filename,
99  GError **error);
101  const gchar *buffer,
102  gsize length,
103  GError **error);
105  const gchar *filename,
106  gchar **object_ids,
107  GError **error);
109  const gchar *buffer,
110  gsize length,
111  gchar **object_ids,
112  GError **error);
114  const gchar *name);
117  gpointer user_data);
120  gpointer user_data);
122  const gchar *domain);
125  const char *type_name);
126 
128  GParamSpec *pspec,
129  const gchar *string,
130  GValue *value,
131  GError **error);
133  GType type,
134  const gchar *string,
135  GValue *value,
136  GError **error);
137 
138 #define GTK_BUILDER_WARN_INVALID_CHILD_TYPE(object, type) \
139  g_warning ("'%s' is not a valid child type of '%s'", type, g_type_name (G_OBJECT_TYPE (object)))
140 
141 G_END_DECLS
142 
143 #endif /* __GTK_BUILDER_H__ */
guint gtk_builder_add_objects_from_string(GtkBuilder *builder, const gchar *buffer, gsize length, gchar **object_ids, GError **error)
gboolean gtk_builder_value_from_string_type(GtkBuilder *builder, GType type, const gchar *string, GValue *value, GError **error)
GQuark gtk_builder_error_quark(void)
GType gtk_builder_get_type_from_name(GtkBuilder *builder, const char *type_name)
guint gtk_builder_add_from_file(GtkBuilder *builder, const gchar *filename, GError **error)
void gtk_builder_connect_signals_full(GtkBuilder *builder, GtkBuilderConnectFunc func, gpointer user_data)
GtkBuilder * gtk_builder_new(void)
struct _GtkBuilderPrivate GtkBuilderPrivate
Definition: gtkbuilder.h:44
GObject * gtk_builder_get_object(GtkBuilder *builder, const gchar *name)
void gtk_builder_set_translation_domain(GtkBuilder *builder, const gchar *domain)
GSList * gtk_builder_get_objects(GtkBuilder *builder)
guint gtk_builder_add_from_string(GtkBuilder *builder, const gchar *buffer, gsize length, GError **error)
GType gtk_builder_get_type(void) G_GNUC_CONST
void gtk_builder_connect_signals(GtkBuilder *builder, gpointer user_data)
guint gtk_builder_add_objects_from_file(GtkBuilder *builder, const gchar *filename, gchar **object_ids, GError **error)
gboolean gtk_builder_value_from_string(GtkBuilder *builder, GParamSpec *pspec, const gchar *string, GValue *value, GError **error)
void(* GtkBuilderConnectFunc)(GtkBuilder *builder, GObject *object, const gchar *signal_name, const gchar *handler_name, GObject *connect_object, GConnectFlags flags, gpointer user_data)
Definition: gtkbuilder.h:86
const gchar * gtk_builder_get_translation_domain(GtkBuilder *builder)
GtkBuilderError
Definition: gtkbuilder.h:47
@ GTK_BUILDER_ERROR_MISSING_ATTRIBUTE
Definition: gtkbuilder.h:50
@ GTK_BUILDER_ERROR_VERSION_MISMATCH
Definition: gtkbuilder.h:55
@ GTK_BUILDER_ERROR_INVALID_TYPE_FUNCTION
Definition: gtkbuilder.h:48
@ GTK_BUILDER_ERROR_MISSING_PROPERTY_VALUE
Definition: gtkbuilder.h:53
@ GTK_BUILDER_ERROR_UNHANDLED_TAG
Definition: gtkbuilder.h:49
@ GTK_BUILDER_ERROR_DUPLICATE_ID
Definition: gtkbuilder.h:56
@ GTK_BUILDER_ERROR_INVALID_VALUE
Definition: gtkbuilder.h:54
@ GTK_BUILDER_ERROR_INVALID_TAG
Definition: gtkbuilder.h:52
@ GTK_BUILDER_ERROR_INVALID_ATTRIBUTE
Definition: gtkbuilder.h:51
GtkImageIconNameData name
Definition: gtkimage.h:6
PBD::PropertyDescriptor< timecnt_t > length
Transmitter error
GObjectClass parent_class
Definition: gtkbuilder.h:70
void(* _gtk_reserved4)(void)
Definition: gtkbuilder.h:79
void(* _gtk_reserved7)(void)
Definition: gtkbuilder.h:82
GType(* get_type_from_name)(GtkBuilder *builder, const char *type_name)
Definition: gtkbuilder.h:72
void(* _gtk_reserved8)(void)
Definition: gtkbuilder.h:83
void(* _gtk_reserved1)(void)
Definition: gtkbuilder.h:76
void(* _gtk_reserved5)(void)
Definition: gtkbuilder.h:80
void(* _gtk_reserved3)(void)
Definition: gtkbuilder.h:78
void(* _gtk_reserved2)(void)
Definition: gtkbuilder.h:77
void(* _gtk_reserved6)(void)
Definition: gtkbuilder.h:81
GObject parent_instance
Definition: gtkbuilder.h:63
GtkBuilderPrivate * GSEAL(priv)