summaryrefslogtreecommitdiff
path: root/gtk/gtkcontainer.h
diff options
context:
space:
mode:
Diffstat (limited to 'gtk/gtkcontainer.h')
-rw-r--r--gtk/gtkcontainer.h64
1 files changed, 60 insertions, 4 deletions
diff --git a/gtk/gtkcontainer.h b/gtk/gtkcontainer.h
index c0315b08bf..62916110c6 100644
--- a/gtk/gtkcontainer.h
+++ b/gtk/gtkcontainer.h
@@ -48,7 +48,7 @@ struct _GtkContainer
GtkWidget *focus_child;
- gint16 border_width;
+ guint border_width : 16;
guint auto_resize : 1;
guint need_resize : 1;
guint block_resize : 1;
@@ -63,6 +63,8 @@ struct _GtkContainerClass
{
GtkWidgetClass parent_class;
+ guint n_child_args;
+
void (* add) (GtkContainer *container,
GtkWidget *widget);
void (* remove) (GtkContainer *container,
@@ -75,13 +77,21 @@ struct _GtkContainerClass
GtkDirectionType direction);
void (* set_focus_child) (GtkContainer *container,
GtkWidget *widget);
+ GtkType (*child_type) (GtkContainer *container);
+ void (*set_child_arg) (GtkContainer *container,
+ GtkWidget *child,
+ GtkArg *arg,
+ guint arg_id);
+ void (*get_child_arg) (GtkContainer *container,
+ GtkWidget *child,
+ GtkArg *arg,
+ guint arg_id);
};
-
GtkType gtk_container_get_type (void);
void gtk_container_border_width (GtkContainer *container,
- gint border_width);
+ guint border_width);
void gtk_container_add (GtkContainer *container,
GtkWidget *widget);
void gtk_container_remove (GtkContainer *container,
@@ -114,7 +124,53 @@ void gtk_container_set_focus_vadjustment (GtkContainer *container,
GtkAdjustment *adjustment);
void gtk_container_set_focus_hadjustment (GtkContainer *container,
GtkAdjustment *adjustment);
-
+
+GtkType gtk_container_child_type (GtkContainer *container);
+
+void gtk_container_add_child_arg_type (const gchar *arg_name,
+ GtkType arg_type,
+ guint arg_flags,
+ guint arg_id);
+
+/* Allocate a GtkArg array of size nargs that hold the
+ * names and types of the args that can be used with
+ * gtk_container_child_arg_get/gtk_container_child_arg_set.
+ * if (arg_flags!=NULL),
+ * (*arg_flags) will be set to point to a newly allocated
+ * guint array that holds the flags of the args.
+ * It is the callers response to do a
+ * g_free (returned_args); g_free (*arg_flags).
+ */
+GtkArg* gtk_container_query_child_args (GtkType class_type,
+ guint32 **arg_flags,
+ guint *nargs);
+
+/* gtk_container_child_arg_getv() sets an arguments type and value, or just
+ * its type to GTK_TYPE_INVALID.
+ * if arg->type == GTK_TYPE_STRING, it's the callers response to
+ * do a g_free (GTK_VALUE_STRING (arg));
+ */
+void gtk_container_child_arg_getv (GtkContainer *container,
+ GtkWidget *child,
+ guint n_args,
+ GtkArg *args);
+void gtk_container_child_arg_setv (GtkContainer *container,
+ GtkWidget *child,
+ guint n_args,
+ GtkArg *args);
+
+/* gtk_container_add_with_args() takes a variable argument list of the form:
+ * (..., gchar *arg_name, ARG_VALUES, [repeatedly name/value pairs,] NULL)
+ * where ARG_VALUES type depend on the argument and can consist of
+ * more than one c-function argument.
+ */
+void gtk_container_add_with_args (GtkContainer *container,
+ GtkWidget *widget,
+ ...);
+void gtk_container_add_with_argv (GtkContainer *container,
+ GtkWidget *widget,
+ guint n_args,
+ GtkArg *args);