summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog102
-rw-r--r--ChangeLog.pre-2-0102
-rw-r--r--ChangeLog.pre-2-10102
-rw-r--r--ChangeLog.pre-2-2102
-rw-r--r--ChangeLog.pre-2-4102
-rw-r--r--ChangeLog.pre-2-6102
-rw-r--r--ChangeLog.pre-2-8102
-rw-r--r--docs/Changes-2.0.txt20
-rw-r--r--docs/reference/Makefile.am2
-rw-r--r--docs/reference/gdk-pixbuf/tmpl/animation.sgml144
-rw-r--r--docs/reference/gdk-pixbuf/tmpl/creating.sgml65
-rw-r--r--docs/reference/gdk-pixbuf/tmpl/file-loading.sgml15
-rw-r--r--docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-unused.sgml1348
-rw-r--r--docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf.sgml132
-rw-r--r--docs/reference/gdk-pixbuf/tmpl/initialization_versions.sgml59
-rw-r--r--docs/reference/gdk-pixbuf/tmpl/module_interface.sgml88
-rw-r--r--docs/reference/gdk-pixbuf/tmpl/refcounting.sgml31
-rw-r--r--docs/reference/gdk-pixbuf/tmpl/scaling.sgml124
-rw-r--r--docs/reference/gdk-pixbuf/tmpl/util.sgml44
-rw-r--r--docs/reference/gdk/tmpl/gdk-unused.sgml196
-rw-r--r--docs/reference/gdk/tmpl/input_devices.sgml6
-rw-r--r--docs/reference/gdk/tmpl/threads.sgml6
-rw-r--r--gdk-pixbuf/gdk-pixbuf-animation.c2
-rw-r--r--gdk-pixbuf/gdk-pixbuf-loader.c30
-rw-r--r--gdk-pixbuf/gdk-pixbuf.c2
-rw-r--r--gdk/gdkdraw.c2
-rw-r--r--gdk/gdkgc.c2
-rw-r--r--gdk/gdkpixmap.c2
-rw-r--r--gdk/gdkwindow.c2
-rw-r--r--gdk/x11/gdkcolor-x11.c2
-rw-r--r--gdk/x11/gdkdnd-x11.c2
-rw-r--r--gdk/x11/gdkdrawable-x11.c2
-rw-r--r--gdk/x11/gdkgc-x11.c2
-rw-r--r--gdk/x11/gdkimage-x11.c2
-rw-r--r--gdk/x11/gdkpixmap-x11.c2
-rw-r--r--gdk/x11/gdkwindow-x11.c2
-rw-r--r--gtk/Makefile.am10
-rw-r--r--gtk/gdk-pixbuf-loader.c30
-rw-r--r--gtk/gtkaccelgroup.c14
-rw-r--r--gtk/gtkadjustment.c4
-rw-r--r--gtk/gtkbindings.c21
-rw-r--r--gtk/gtkbutton.c12
-rw-r--r--gtk/gtkcalendar.c2
-rw-r--r--gtk/gtkcellrenderer.c2
-rw-r--r--gtk/gtkcellrendererpixbuf.c2
-rw-r--r--gtk/gtkcellrenderertext.c2
-rw-r--r--gtk/gtkcellrenderertextpixbuf.c2
-rw-r--r--gtk/gtkcellrenderertoggle.c4
-rw-r--r--gtk/gtkcheckmenuitem.c2
-rw-r--r--gtk/gtkclist.c34
-rw-r--r--gtk/gtkcolorsel.c2
-rw-r--r--gtk/gtkcontainer.c8
-rw-r--r--gtk/gtkctree.c12
-rw-r--r--gtk/gtkcurve.c2
-rw-r--r--gtk/gtkdata.c2
-rw-r--r--gtk/gtkeditable.c32
-rw-r--r--gtk/gtkenums.h12
-rw-r--r--gtk/gtkhandlebox.c4
-rw-r--r--gtk/gtkhsv.c2
-rw-r--r--gtk/gtkiconfactory.c2
-rw-r--r--gtk/gtkimcontext.c8
-rw-r--r--gtk/gtkinputdialog.c4
-rw-r--r--gtk/gtkitem.c6
-rw-r--r--gtk/gtklabel.c2
-rw-r--r--gtk/gtklayout.c4
-rw-r--r--gtk/gtklist.c6
-rw-r--r--gtk/gtklistitem.c26
-rw-r--r--gtk/gtkliststore.c10
-rw-r--r--gtk/gtkmain.c2
-rw-r--r--gtk/gtkmarshal.list93
-rw-r--r--gtk/gtkmarshalers.list93
-rw-r--r--gtk/gtkmenuitem.c4
-rw-r--r--gtk/gtkmenushell.c10
-rw-r--r--gtk/gtkmodelsimple.c17
-rw-r--r--gtk/gtknotebook.c2
-rw-r--r--gtk/gtkobject.c26
-rw-r--r--gtk/gtkobject.h2
-rw-r--r--gtk/gtkplug.c2
-rw-r--r--gtk/gtkrc.c2
-rw-r--r--gtk/gtksignal.c2168
-rw-r--r--gtk/gtksignal.h257
-rw-r--r--gtk/gtksocket.c2
-rw-r--r--gtk/gtkspinbutton.c2
-rw-r--r--gtk/gtkstatusbar.c4
-rw-r--r--gtk/gtkstyle.c2
-rw-r--r--gtk/gtktext.c2
-rw-r--r--gtk/gtktextbuffer.c45
-rw-r--r--gtk/gtktextlayout.c30
-rw-r--r--gtk/gtktextmark.c2
-rw-r--r--gtk/gtktexttagtable.c6
-rw-r--r--gtk/gtktextview.c18
-rw-r--r--gtk/gtkthemes.c2
-rw-r--r--gtk/gtktipsquery.c8
-rw-r--r--gtk/gtktogglebutton.c2
-rw-r--r--gtk/gtktoolbar.c4
-rw-r--r--gtk/gtktree.c6
-rw-r--r--gtk/gtktreeitem.c4
-rw-r--r--gtk/gtktreemodel.c2
-rw-r--r--gtk/gtktreeselection.c4
-rw-r--r--gtk/gtktreestore.c10
-rw-r--r--gtk/gtktreeview.c4
-rw-r--r--gtk/gtktreeviewcolumn.c4
-rw-r--r--gtk/gtktypeutils.c35
-rw-r--r--gtk/gtktypeutils.h9
-rw-r--r--gtk/gtkviewport.c2
-rw-r--r--gtk/gtkwidget.c106
-rw-r--r--gtk/gtkwindow.c2
-rw-r--r--gtk/maketypes.awk39
108 files changed, 2736 insertions, 3633 deletions
diff --git a/ChangeLog b/ChangeLog
index e6f54639a..b2ffe6305 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,105 @@
+Wed Oct 25 20:47:41 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gdk-pixbuf-loader.c (gdk_pixbuf_loader_class_init): urg, removed
+ implementation of gtk_marshal_VOID__INT_INT_INT_INT. if people do that,
+ couldn't they at least give it a non-standard name?
+
+ * gtk/gtktextlayout.c: arg! yet another implementation of
+ gtk_marshal_VOID__INT_INT_INT_INT(), is this a conspiracy?
+
+ * gtk/gtktextbuffer.c: gotcha! captured a vagabonding
+ gtk_marshal_VOID__INT_POINTER_INT() implementation, braught it back
+ home. now i know this _is_ a conspiracy.
+
+ * gtk/gtkwidget.c (gtk_widget_class_init): marshaller fixups for
+ ::state-changed.
+
+ * gtk/gtkaccelgroup.c (gtk_accel_group_create_remove):
+ (gtk_accel_group_create_add): marshaller signature fixups.
+
+ * gtk/gtklistitem.c (gtk_list_item_class_init): signal creation fixups,
+ pass in GTK_TYPE_SCROLL_TYPE instead of GTK_TYPE_ENUM.
+
+ * gtk/gtkobject.[hc]: removed GTK_CONNECTED flag, it's not valid
+ anymore.
+
+Tue Oct 24 23:59:21 2000 Tim Janik <timj@gtk.org>
+
+ * docs/reference/Makefile.am: disabled SUBDIRS for the moment, since
+ due to the signal system changes, it wouldn't build currently. to
+ be fixed soon.
+
+ * docs/Changes-2.0.txt: GtkSignal/GSignal updates.
+
+ * gtk/gtkwidget.c: ::direction_changed takes an enum as argument,
+ so it needs gtk_marshal_VOID__ENUM() instead of
+ gtk_marshal_NONE__UINT().
+
+ * gdk/gdk*.c: adapted type registration functions.
+
+ * gtk/gtkbindings.c:
+ * gtk/gtkaccelgroup.c: operate on GSignalQuery, GtkSignalQuery is
+ gone.
+
+ * gtk/gtkenums.h: define GtkSignalRunType in terms of GSignalType.
+
+ * gtk/gtkobject.c:
+ (gtk_object_destroy):
+ (gtk_object_shutdown): fixed recursion guards. basically we have to
+ catch the case where any of GObject.shutdown() or gtk_object_destroy()
+ is called during ::destroy, and avoid recursion there.
+
+ * gtk/gtktypeutils.c:
+ * gtk/maketypes.awk: awk-script hackup to provide gtk_type_init() with
+ boxed_copy/boxed_free. this needs a more general solution based on a
+ publically installed code-generator utility.
+
+ * gtk/gtktypeutils.[hc]: compat aliased GTK_TYPE_BOXED to G_TYPE_BOXED,
+ glib's gobject has support for that now.
+ define GtkSignalMarshaller in terms of GSignalCMarshaller.
+
+Mon Oct 23 09:36:42 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtksignal.[hc]:
+ * gtk/gtkmarshal.[hc]:
+ * gtk/Makefile.am: generate marshallers with glib-genmarshal and don't
+ compile gtkmarshal.c on its own anymore, just include it in gtksignal.c.
+ removed #include <gtkmarshal.h>s all over the place, gtksignal.h takes
+ care of that.
+
+ * *.c: marshaller name fixups.
+
+ * gtk/gtkmarshal.list: added a comment briefing the format.
+
+Sun Oct 22 23:14:39 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtksignal.[hc]: nuked old implementation. we mostly have
+ compatibility macros here now. more specifically, most of
+ the API is preserved (yes, _most_, nonwithstanding the
+ following exceptions listed, the API is stil lHUGE ;)
+ things that got removed completely:
+ GtkSignalQuery, gtk_signal_query(), gtk_signal_n_emissions(),
+ gtk_signal_n_emissions_by_name(), gtk_signal_handlers_destroy(),
+ gtk_signal_set_funcs(), gtk_signal_handler_pending_by_id(),
+ gtk_signal_add_emission_hook(), gtk_signal_add_emission_hook_full(),
+ gtk_signal_remove_emission_hook().
+ non-functional functions variants:
+ gtk_signal_add_emission_hook(), gtk_signal_remove_emission_hook().
+ the GtkCallbackMarshal argument to gtk_signal_connect_full() is
+ not supported anymore.
+ (gtk_signal_compat_matched): new internal function to aid
+ implementation of the compatibility macros, it provides
+ functionality to block/unblock/disconnect handlers based
+ on func/data.
+
+ * gtk/gtkenums.h: define GtkSignalRunType in terms of GSignalType,
+
+ * *.c: adaptions to new type registration API signatures.
+
+Fri Oct 20 15:26:33 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtktypeutils.[hc]: removed G_TYPE_GTK_POINTER cludge.
+
2000-10-25 Robert Brady <robert@suse.co.uk>
* gdk/x11/gdkproperty-x11.c (gdk_property_get, gdk_property_change,
diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0
index e6f54639a..b2ffe6305 100644
--- a/ChangeLog.pre-2-0
+++ b/ChangeLog.pre-2-0
@@ -1,3 +1,105 @@
+Wed Oct 25 20:47:41 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gdk-pixbuf-loader.c (gdk_pixbuf_loader_class_init): urg, removed
+ implementation of gtk_marshal_VOID__INT_INT_INT_INT. if people do that,
+ couldn't they at least give it a non-standard name?
+
+ * gtk/gtktextlayout.c: arg! yet another implementation of
+ gtk_marshal_VOID__INT_INT_INT_INT(), is this a conspiracy?
+
+ * gtk/gtktextbuffer.c: gotcha! captured a vagabonding
+ gtk_marshal_VOID__INT_POINTER_INT() implementation, braught it back
+ home. now i know this _is_ a conspiracy.
+
+ * gtk/gtkwidget.c (gtk_widget_class_init): marshaller fixups for
+ ::state-changed.
+
+ * gtk/gtkaccelgroup.c (gtk_accel_group_create_remove):
+ (gtk_accel_group_create_add): marshaller signature fixups.
+
+ * gtk/gtklistitem.c (gtk_list_item_class_init): signal creation fixups,
+ pass in GTK_TYPE_SCROLL_TYPE instead of GTK_TYPE_ENUM.
+
+ * gtk/gtkobject.[hc]: removed GTK_CONNECTED flag, it's not valid
+ anymore.
+
+Tue Oct 24 23:59:21 2000 Tim Janik <timj@gtk.org>
+
+ * docs/reference/Makefile.am: disabled SUBDIRS for the moment, since
+ due to the signal system changes, it wouldn't build currently. to
+ be fixed soon.
+
+ * docs/Changes-2.0.txt: GtkSignal/GSignal updates.
+
+ * gtk/gtkwidget.c: ::direction_changed takes an enum as argument,
+ so it needs gtk_marshal_VOID__ENUM() instead of
+ gtk_marshal_NONE__UINT().
+
+ * gdk/gdk*.c: adapted type registration functions.
+
+ * gtk/gtkbindings.c:
+ * gtk/gtkaccelgroup.c: operate on GSignalQuery, GtkSignalQuery is
+ gone.
+
+ * gtk/gtkenums.h: define GtkSignalRunType in terms of GSignalType.
+
+ * gtk/gtkobject.c:
+ (gtk_object_destroy):
+ (gtk_object_shutdown): fixed recursion guards. basically we have to
+ catch the case where any of GObject.shutdown() or gtk_object_destroy()
+ is called during ::destroy, and avoid recursion there.
+
+ * gtk/gtktypeutils.c:
+ * gtk/maketypes.awk: awk-script hackup to provide gtk_type_init() with
+ boxed_copy/boxed_free. this needs a more general solution based on a
+ publically installed code-generator utility.
+
+ * gtk/gtktypeutils.[hc]: compat aliased GTK_TYPE_BOXED to G_TYPE_BOXED,
+ glib's gobject has support for that now.
+ define GtkSignalMarshaller in terms of GSignalCMarshaller.
+
+Mon Oct 23 09:36:42 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtksignal.[hc]:
+ * gtk/gtkmarshal.[hc]:
+ * gtk/Makefile.am: generate marshallers with glib-genmarshal and don't
+ compile gtkmarshal.c on its own anymore, just include it in gtksignal.c.
+ removed #include <gtkmarshal.h>s all over the place, gtksignal.h takes
+ care of that.
+
+ * *.c: marshaller name fixups.
+
+ * gtk/gtkmarshal.list: added a comment briefing the format.
+
+Sun Oct 22 23:14:39 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtksignal.[hc]: nuked old implementation. we mostly have
+ compatibility macros here now. more specifically, most of
+ the API is preserved (yes, _most_, nonwithstanding the
+ following exceptions listed, the API is stil lHUGE ;)
+ things that got removed completely:
+ GtkSignalQuery, gtk_signal_query(), gtk_signal_n_emissions(),
+ gtk_signal_n_emissions_by_name(), gtk_signal_handlers_destroy(),
+ gtk_signal_set_funcs(), gtk_signal_handler_pending_by_id(),
+ gtk_signal_add_emission_hook(), gtk_signal_add_emission_hook_full(),
+ gtk_signal_remove_emission_hook().
+ non-functional functions variants:
+ gtk_signal_add_emission_hook(), gtk_signal_remove_emission_hook().
+ the GtkCallbackMarshal argument to gtk_signal_connect_full() is
+ not supported anymore.
+ (gtk_signal_compat_matched): new internal function to aid
+ implementation of the compatibility macros, it provides
+ functionality to block/unblock/disconnect handlers based
+ on func/data.
+
+ * gtk/gtkenums.h: define GtkSignalRunType in terms of GSignalType,
+
+ * *.c: adaptions to new type registration API signatures.
+
+Fri Oct 20 15:26:33 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtktypeutils.[hc]: removed G_TYPE_GTK_POINTER cludge.
+
2000-10-25 Robert Brady <robert@suse.co.uk>
* gdk/x11/gdkproperty-x11.c (gdk_property_get, gdk_property_change,
diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10
index e6f54639a..b2ffe6305 100644
--- a/ChangeLog.pre-2-10
+++ b/ChangeLog.pre-2-10
@@ -1,3 +1,105 @@
+Wed Oct 25 20:47:41 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gdk-pixbuf-loader.c (gdk_pixbuf_loader_class_init): urg, removed
+ implementation of gtk_marshal_VOID__INT_INT_INT_INT. if people do that,
+ couldn't they at least give it a non-standard name?
+
+ * gtk/gtktextlayout.c: arg! yet another implementation of
+ gtk_marshal_VOID__INT_INT_INT_INT(), is this a conspiracy?
+
+ * gtk/gtktextbuffer.c: gotcha! captured a vagabonding
+ gtk_marshal_VOID__INT_POINTER_INT() implementation, braught it back
+ home. now i know this _is_ a conspiracy.
+
+ * gtk/gtkwidget.c (gtk_widget_class_init): marshaller fixups for
+ ::state-changed.
+
+ * gtk/gtkaccelgroup.c (gtk_accel_group_create_remove):
+ (gtk_accel_group_create_add): marshaller signature fixups.
+
+ * gtk/gtklistitem.c (gtk_list_item_class_init): signal creation fixups,
+ pass in GTK_TYPE_SCROLL_TYPE instead of GTK_TYPE_ENUM.
+
+ * gtk/gtkobject.[hc]: removed GTK_CONNECTED flag, it's not valid
+ anymore.
+
+Tue Oct 24 23:59:21 2000 Tim Janik <timj@gtk.org>
+
+ * docs/reference/Makefile.am: disabled SUBDIRS for the moment, since
+ due to the signal system changes, it wouldn't build currently. to
+ be fixed soon.
+
+ * docs/Changes-2.0.txt: GtkSignal/GSignal updates.
+
+ * gtk/gtkwidget.c: ::direction_changed takes an enum as argument,
+ so it needs gtk_marshal_VOID__ENUM() instead of
+ gtk_marshal_NONE__UINT().
+
+ * gdk/gdk*.c: adapted type registration functions.
+
+ * gtk/gtkbindings.c:
+ * gtk/gtkaccelgroup.c: operate on GSignalQuery, GtkSignalQuery is
+ gone.
+
+ * gtk/gtkenums.h: define GtkSignalRunType in terms of GSignalType.
+
+ * gtk/gtkobject.c:
+ (gtk_object_destroy):
+ (gtk_object_shutdown): fixed recursion guards. basically we have to
+ catch the case where any of GObject.shutdown() or gtk_object_destroy()
+ is called during ::destroy, and avoid recursion there.
+
+ * gtk/gtktypeutils.c:
+ * gtk/maketypes.awk: awk-script hackup to provide gtk_type_init() with
+ boxed_copy/boxed_free. this needs a more general solution based on a
+ publically installed code-generator utility.
+
+ * gtk/gtktypeutils.[hc]: compat aliased GTK_TYPE_BOXED to G_TYPE_BOXED,
+ glib's gobject has support for that now.
+ define GtkSignalMarshaller in terms of GSignalCMarshaller.
+
+Mon Oct 23 09:36:42 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtksignal.[hc]:
+ * gtk/gtkmarshal.[hc]:
+ * gtk/Makefile.am: generate marshallers with glib-genmarshal and don't
+ compile gtkmarshal.c on its own anymore, just include it in gtksignal.c.
+ removed #include <gtkmarshal.h>s all over the place, gtksignal.h takes
+ care of that.
+
+ * *.c: marshaller name fixups.
+
+ * gtk/gtkmarshal.list: added a comment briefing the format.
+
+Sun Oct 22 23:14:39 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtksignal.[hc]: nuked old implementation. we mostly have
+ compatibility macros here now. more specifically, most of
+ the API is preserved (yes, _most_, nonwithstanding the
+ following exceptions listed, the API is stil lHUGE ;)
+ things that got removed completely:
+ GtkSignalQuery, gtk_signal_query(), gtk_signal_n_emissions(),
+ gtk_signal_n_emissions_by_name(), gtk_signal_handlers_destroy(),
+ gtk_signal_set_funcs(), gtk_signal_handler_pending_by_id(),
+ gtk_signal_add_emission_hook(), gtk_signal_add_emission_hook_full(),
+ gtk_signal_remove_emission_hook().
+ non-functional functions variants:
+ gtk_signal_add_emission_hook(), gtk_signal_remove_emission_hook().
+ the GtkCallbackMarshal argument to gtk_signal_connect_full() is
+ not supported anymore.
+ (gtk_signal_compat_matched): new internal function to aid
+ implementation of the compatibility macros, it provides
+ functionality to block/unblock/disconnect handlers based
+ on func/data.
+
+ * gtk/gtkenums.h: define GtkSignalRunType in terms of GSignalType,
+
+ * *.c: adaptions to new type registration API signatures.
+
+Fri Oct 20 15:26:33 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtktypeutils.[hc]: removed G_TYPE_GTK_POINTER cludge.
+
2000-10-25 Robert Brady <robert@suse.co.uk>
* gdk/x11/gdkproperty-x11.c (gdk_property_get, gdk_property_change,
diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2
index e6f54639a..b2ffe6305 100644
--- a/ChangeLog.pre-2-2
+++ b/ChangeLog.pre-2-2
@@ -1,3 +1,105 @@
+Wed Oct 25 20:47:41 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gdk-pixbuf-loader.c (gdk_pixbuf_loader_class_init): urg, removed
+ implementation of gtk_marshal_VOID__INT_INT_INT_INT. if people do that,
+ couldn't they at least give it a non-standard name?
+
+ * gtk/gtktextlayout.c: arg! yet another implementation of
+ gtk_marshal_VOID__INT_INT_INT_INT(), is this a conspiracy?
+
+ * gtk/gtktextbuffer.c: gotcha! captured a vagabonding
+ gtk_marshal_VOID__INT_POINTER_INT() implementation, braught it back
+ home. now i know this _is_ a conspiracy.
+
+ * gtk/gtkwidget.c (gtk_widget_class_init): marshaller fixups for
+ ::state-changed.
+
+ * gtk/gtkaccelgroup.c (gtk_accel_group_create_remove):
+ (gtk_accel_group_create_add): marshaller signature fixups.
+
+ * gtk/gtklistitem.c (gtk_list_item_class_init): signal creation fixups,
+ pass in GTK_TYPE_SCROLL_TYPE instead of GTK_TYPE_ENUM.
+
+ * gtk/gtkobject.[hc]: removed GTK_CONNECTED flag, it's not valid
+ anymore.
+
+Tue Oct 24 23:59:21 2000 Tim Janik <timj@gtk.org>
+
+ * docs/reference/Makefile.am: disabled SUBDIRS for the moment, since
+ due to the signal system changes, it wouldn't build currently. to
+ be fixed soon.
+
+ * docs/Changes-2.0.txt: GtkSignal/GSignal updates.
+
+ * gtk/gtkwidget.c: ::direction_changed takes an enum as argument,
+ so it needs gtk_marshal_VOID__ENUM() instead of
+ gtk_marshal_NONE__UINT().
+
+ * gdk/gdk*.c: adapted type registration functions.
+
+ * gtk/gtkbindings.c:
+ * gtk/gtkaccelgroup.c: operate on GSignalQuery, GtkSignalQuery is
+ gone.
+
+ * gtk/gtkenums.h: define GtkSignalRunType in terms of GSignalType.
+
+ * gtk/gtkobject.c:
+ (gtk_object_destroy):
+ (gtk_object_shutdown): fixed recursion guards. basically we have to
+ catch the case where any of GObject.shutdown() or gtk_object_destroy()
+ is called during ::destroy, and avoid recursion there.
+
+ * gtk/gtktypeutils.c:
+ * gtk/maketypes.awk: awk-script hackup to provide gtk_type_init() with
+ boxed_copy/boxed_free. this needs a more general solution based on a
+ publically installed code-generator utility.
+
+ * gtk/gtktypeutils.[hc]: compat aliased GTK_TYPE_BOXED to G_TYPE_BOXED,
+ glib's gobject has support for that now.
+ define GtkSignalMarshaller in terms of GSignalCMarshaller.
+
+Mon Oct 23 09:36:42 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtksignal.[hc]:
+ * gtk/gtkmarshal.[hc]:
+ * gtk/Makefile.am: generate marshallers with glib-genmarshal and don't
+ compile gtkmarshal.c on its own anymore, just include it in gtksignal.c.
+ removed #include <gtkmarshal.h>s all over the place, gtksignal.h takes
+ care of that.
+
+ * *.c: marshaller name fixups.
+
+ * gtk/gtkmarshal.list: added a comment briefing the format.
+
+Sun Oct 22 23:14:39 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtksignal.[hc]: nuked old implementation. we mostly have
+ compatibility macros here now. more specifically, most of
+ the API is preserved (yes, _most_, nonwithstanding the
+ following exceptions listed, the API is stil lHUGE ;)
+ things that got removed completely:
+ GtkSignalQuery, gtk_signal_query(), gtk_signal_n_emissions(),
+ gtk_signal_n_emissions_by_name(), gtk_signal_handlers_destroy(),
+ gtk_signal_set_funcs(), gtk_signal_handler_pending_by_id(),
+ gtk_signal_add_emission_hook(), gtk_signal_add_emission_hook_full(),
+ gtk_signal_remove_emission_hook().
+ non-functional functions variants:
+ gtk_signal_add_emission_hook(), gtk_signal_remove_emission_hook().
+ the GtkCallbackMarshal argument to gtk_signal_connect_full() is
+ not supported anymore.
+ (gtk_signal_compat_matched): new internal function to aid
+ implementation of the compatibility macros, it provides
+ functionality to block/unblock/disconnect handlers based
+ on func/data.
+
+ * gtk/gtkenums.h: define GtkSignalRunType in terms of GSignalType,
+
+ * *.c: adaptions to new type registration API signatures.
+
+Fri Oct 20 15:26:33 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtktypeutils.[hc]: removed G_TYPE_GTK_POINTER cludge.
+
2000-10-25 Robert Brady <robert@suse.co.uk>
* gdk/x11/gdkproperty-x11.c (gdk_property_get, gdk_property_change,
diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4
index e6f54639a..b2ffe6305 100644
--- a/ChangeLog.pre-2-4
+++ b/ChangeLog.pre-2-4
@@ -1,3 +1,105 @@
+Wed Oct 25 20:47:41 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gdk-pixbuf-loader.c (gdk_pixbuf_loader_class_init): urg, removed
+ implementation of gtk_marshal_VOID__INT_INT_INT_INT. if people do that,
+ couldn't they at least give it a non-standard name?
+
+ * gtk/gtktextlayout.c: arg! yet another implementation of
+ gtk_marshal_VOID__INT_INT_INT_INT(), is this a conspiracy?
+
+ * gtk/gtktextbuffer.c: gotcha! captured a vagabonding
+ gtk_marshal_VOID__INT_POINTER_INT() implementation, braught it back
+ home. now i know this _is_ a conspiracy.
+
+ * gtk/gtkwidget.c (gtk_widget_class_init): marshaller fixups for
+ ::state-changed.
+
+ * gtk/gtkaccelgroup.c (gtk_accel_group_create_remove):
+ (gtk_accel_group_create_add): marshaller signature fixups.
+
+ * gtk/gtklistitem.c (gtk_list_item_class_init): signal creation fixups,
+ pass in GTK_TYPE_SCROLL_TYPE instead of GTK_TYPE_ENUM.
+
+ * gtk/gtkobject.[hc]: removed GTK_CONNECTED flag, it's not valid
+ anymore.
+
+Tue Oct 24 23:59:21 2000 Tim Janik <timj@gtk.org>
+
+ * docs/reference/Makefile.am: disabled SUBDIRS for the moment, since
+ due to the signal system changes, it wouldn't build currently. to
+ be fixed soon.
+
+ * docs/Changes-2.0.txt: GtkSignal/GSignal updates.
+
+ * gtk/gtkwidget.c: ::direction_changed takes an enum as argument,
+ so it needs gtk_marshal_VOID__ENUM() instead of
+ gtk_marshal_NONE__UINT().
+
+ * gdk/gdk*.c: adapted type registration functions.
+
+ * gtk/gtkbindings.c:
+ * gtk/gtkaccelgroup.c: operate on GSignalQuery, GtkSignalQuery is
+ gone.
+
+ * gtk/gtkenums.h: define GtkSignalRunType in terms of GSignalType.
+
+ * gtk/gtkobject.c:
+ (gtk_object_destroy):
+ (gtk_object_shutdown): fixed recursion guards. basically we have to
+ catch the case where any of GObject.shutdown() or gtk_object_destroy()
+ is called during ::destroy, and avoid recursion there.
+
+ * gtk/gtktypeutils.c:
+ * gtk/maketypes.awk: awk-script hackup to provide gtk_type_init() with
+ boxed_copy/boxed_free. this needs a more general solution based on a
+ publically installed code-generator utility.
+
+ * gtk/gtktypeutils.[hc]: compat aliased GTK_TYPE_BOXED to G_TYPE_BOXED,
+ glib's gobject has support for that now.
+ define GtkSignalMarshaller in terms of GSignalCMarshaller.
+
+Mon Oct 23 09:36:42 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtksignal.[hc]:
+ * gtk/gtkmarshal.[hc]:
+ * gtk/Makefile.am: generate marshallers with glib-genmarshal and don't
+ compile gtkmarshal.c on its own anymore, just include it in gtksignal.c.
+ removed #include <gtkmarshal.h>s all over the place, gtksignal.h takes
+ care of that.
+
+ * *.c: marshaller name fixups.
+
+ * gtk/gtkmarshal.list: added a comment briefing the format.
+
+Sun Oct 22 23:14:39 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtksignal.[hc]: nuked old implementation. we mostly have
+ compatibility macros here now. more specifically, most of
+ the API is preserved (yes, _most_, nonwithstanding the
+ following exceptions listed, the API is stil lHUGE ;)
+ things that got removed completely:
+ GtkSignalQuery, gtk_signal_query(), gtk_signal_n_emissions(),
+ gtk_signal_n_emissions_by_name(), gtk_signal_handlers_destroy(),
+ gtk_signal_set_funcs(), gtk_signal_handler_pending_by_id(),
+ gtk_signal_add_emission_hook(), gtk_signal_add_emission_hook_full(),
+ gtk_signal_remove_emission_hook().
+ non-functional functions variants:
+ gtk_signal_add_emission_hook(), gtk_signal_remove_emission_hook().
+ the GtkCallbackMarshal argument to gtk_signal_connect_full() is
+ not supported anymore.
+ (gtk_signal_compat_matched): new internal function to aid
+ implementation of the compatibility macros, it provides
+ functionality to block/unblock/disconnect handlers based
+ on func/data.
+
+ * gtk/gtkenums.h: define GtkSignalRunType in terms of GSignalType,
+
+ * *.c: adaptions to new type registration API signatures.
+
+Fri Oct 20 15:26:33 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtktypeutils.[hc]: removed G_TYPE_GTK_POINTER cludge.
+
2000-10-25 Robert Brady <robert@suse.co.uk>
* gdk/x11/gdkproperty-x11.c (gdk_property_get, gdk_property_change,
diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6
index e6f54639a..b2ffe6305 100644
--- a/ChangeLog.pre-2-6
+++ b/ChangeLog.pre-2-6
@@ -1,3 +1,105 @@
+Wed Oct 25 20:47:41 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gdk-pixbuf-loader.c (gdk_pixbuf_loader_class_init): urg, removed
+ implementation of gtk_marshal_VOID__INT_INT_INT_INT. if people do that,
+ couldn't they at least give it a non-standard name?
+
+ * gtk/gtktextlayout.c: arg! yet another implementation of
+ gtk_marshal_VOID__INT_INT_INT_INT(), is this a conspiracy?
+
+ * gtk/gtktextbuffer.c: gotcha! captured a vagabonding
+ gtk_marshal_VOID__INT_POINTER_INT() implementation, braught it back
+ home. now i know this _is_ a conspiracy.
+
+ * gtk/gtkwidget.c (gtk_widget_class_init): marshaller fixups for
+ ::state-changed.
+
+ * gtk/gtkaccelgroup.c (gtk_accel_group_create_remove):
+ (gtk_accel_group_create_add): marshaller signature fixups.
+
+ * gtk/gtklistitem.c (gtk_list_item_class_init): signal creation fixups,
+ pass in GTK_TYPE_SCROLL_TYPE instead of GTK_TYPE_ENUM.
+
+ * gtk/gtkobject.[hc]: removed GTK_CONNECTED flag, it's not valid
+ anymore.
+
+Tue Oct 24 23:59:21 2000 Tim Janik <timj@gtk.org>
+
+ * docs/reference/Makefile.am: disabled SUBDIRS for the moment, since
+ due to the signal system changes, it wouldn't build currently. to
+ be fixed soon.
+
+ * docs/Changes-2.0.txt: GtkSignal/GSignal updates.
+
+ * gtk/gtkwidget.c: ::direction_changed takes an enum as argument,
+ so it needs gtk_marshal_VOID__ENUM() instead of
+ gtk_marshal_NONE__UINT().
+
+ * gdk/gdk*.c: adapted type registration functions.
+
+ * gtk/gtkbindings.c:
+ * gtk/gtkaccelgroup.c: operate on GSignalQuery, GtkSignalQuery is
+ gone.
+
+ * gtk/gtkenums.h: define GtkSignalRunType in terms of GSignalType.
+
+ * gtk/gtkobject.c:
+ (gtk_object_destroy):
+ (gtk_object_shutdown): fixed recursion guards. basically we have to
+ catch the case where any of GObject.shutdown() or gtk_object_destroy()
+ is called during ::destroy, and avoid recursion there.
+
+ * gtk/gtktypeutils.c:
+ * gtk/maketypes.awk: awk-script hackup to provide gtk_type_init() with
+ boxed_copy/boxed_free. this needs a more general solution based on a
+ publically installed code-generator utility.
+
+ * gtk/gtktypeutils.[hc]: compat aliased GTK_TYPE_BOXED to G_TYPE_BOXED,
+ glib's gobject has support for that now.
+ define GtkSignalMarshaller in terms of GSignalCMarshaller.
+
+Mon Oct 23 09:36:42 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtksignal.[hc]:
+ * gtk/gtkmarshal.[hc]:
+ * gtk/Makefile.am: generate marshallers with glib-genmarshal and don't
+ compile gtkmarshal.c on its own anymore, just include it in gtksignal.c.
+ removed #include <gtkmarshal.h>s all over the place, gtksignal.h takes
+ care of that.
+
+ * *.c: marshaller name fixups.
+
+ * gtk/gtkmarshal.list: added a comment briefing the format.
+
+Sun Oct 22 23:14:39 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtksignal.[hc]: nuked old implementation. we mostly have
+ compatibility macros here now. more specifically, most of
+ the API is preserved (yes, _most_, nonwithstanding the
+ following exceptions listed, the API is stil lHUGE ;)
+ things that got removed completely:
+ GtkSignalQuery, gtk_signal_query(), gtk_signal_n_emissions(),
+ gtk_signal_n_emissions_by_name(), gtk_signal_handlers_destroy(),
+ gtk_signal_set_funcs(), gtk_signal_handler_pending_by_id(),
+ gtk_signal_add_emission_hook(), gtk_signal_add_emission_hook_full(),
+ gtk_signal_remove_emission_hook().
+ non-functional functions variants:
+ gtk_signal_add_emission_hook(), gtk_signal_remove_emission_hook().
+ the GtkCallbackMarshal argument to gtk_signal_connect_full() is
+ not supported anymore.
+ (gtk_signal_compat_matched): new internal function to aid
+ implementation of the compatibility macros, it provides
+ functionality to block/unblock/disconnect handlers based
+ on func/data.
+
+ * gtk/gtkenums.h: define GtkSignalRunType in terms of GSignalType,
+
+ * *.c: adaptions to new type registration API signatures.
+
+Fri Oct 20 15:26:33 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtktypeutils.[hc]: removed G_TYPE_GTK_POINTER cludge.
+
2000-10-25 Robert Brady <robert@suse.co.uk>
* gdk/x11/gdkproperty-x11.c (gdk_property_get, gdk_property_change,
diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8
index e6f54639a..b2ffe6305 100644
--- a/ChangeLog.pre-2-8
+++ b/ChangeLog.pre-2-8
@@ -1,3 +1,105 @@
+Wed Oct 25 20:47:41 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gdk-pixbuf-loader.c (gdk_pixbuf_loader_class_init): urg, removed
+ implementation of gtk_marshal_VOID__INT_INT_INT_INT. if people do that,
+ couldn't they at least give it a non-standard name?
+
+ * gtk/gtktextlayout.c: arg! yet another implementation of
+ gtk_marshal_VOID__INT_INT_INT_INT(), is this a conspiracy?
+
+ * gtk/gtktextbuffer.c: gotcha! captured a vagabonding
+ gtk_marshal_VOID__INT_POINTER_INT() implementation, braught it back
+ home. now i know this _is_ a conspiracy.
+
+ * gtk/gtkwidget.c (gtk_widget_class_init): marshaller fixups for
+ ::state-changed.
+
+ * gtk/gtkaccelgroup.c (gtk_accel_group_create_remove):
+ (gtk_accel_group_create_add): marshaller signature fixups.
+
+ * gtk/gtklistitem.c (gtk_list_item_class_init): signal creation fixups,
+ pass in GTK_TYPE_SCROLL_TYPE instead of GTK_TYPE_ENUM.
+
+ * gtk/gtkobject.[hc]: removed GTK_CONNECTED flag, it's not valid
+ anymore.
+
+Tue Oct 24 23:59:21 2000 Tim Janik <timj@gtk.org>
+
+ * docs/reference/Makefile.am: disabled SUBDIRS for the moment, since
+ due to the signal system changes, it wouldn't build currently. to
+ be fixed soon.
+
+ * docs/Changes-2.0.txt: GtkSignal/GSignal updates.
+
+ * gtk/gtkwidget.c: ::direction_changed takes an enum as argument,
+ so it needs gtk_marshal_VOID__ENUM() instead of
+ gtk_marshal_NONE__UINT().
+
+ * gdk/gdk*.c: adapted type registration functions.
+
+ * gtk/gtkbindings.c:
+ * gtk/gtkaccelgroup.c: operate on GSignalQuery, GtkSignalQuery is
+ gone.
+
+ * gtk/gtkenums.h: define GtkSignalRunType in terms of GSignalType.
+
+ * gtk/gtkobject.c:
+ (gtk_object_destroy):
+ (gtk_object_shutdown): fixed recursion guards. basically we have to
+ catch the case where any of GObject.shutdown() or gtk_object_destroy()
+ is called during ::destroy, and avoid recursion there.
+
+ * gtk/gtktypeutils.c:
+ * gtk/maketypes.awk: awk-script hackup to provide gtk_type_init() with
+ boxed_copy/boxed_free. this needs a more general solution based on a
+ publically installed code-generator utility.
+
+ * gtk/gtktypeutils.[hc]: compat aliased GTK_TYPE_BOXED to G_TYPE_BOXED,
+ glib's gobject has support for that now.
+ define GtkSignalMarshaller in terms of GSignalCMarshaller.
+
+Mon Oct 23 09:36:42 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtksignal.[hc]:
+ * gtk/gtkmarshal.[hc]:
+ * gtk/Makefile.am: generate marshallers with glib-genmarshal and don't
+ compile gtkmarshal.c on its own anymore, just include it in gtksignal.c.
+ removed #include <gtkmarshal.h>s all over the place, gtksignal.h takes
+ care of that.
+
+ * *.c: marshaller name fixups.
+
+ * gtk/gtkmarshal.list: added a comment briefing the format.
+
+Sun Oct 22 23:14:39 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtksignal.[hc]: nuked old implementation. we mostly have
+ compatibility macros here now. more specifically, most of
+ the API is preserved (yes, _most_, nonwithstanding the
+ following exceptions listed, the API is stil lHUGE ;)
+ things that got removed completely:
+ GtkSignalQuery, gtk_signal_query(), gtk_signal_n_emissions(),
+ gtk_signal_n_emissions_by_name(), gtk_signal_handlers_destroy(),
+ gtk_signal_set_funcs(), gtk_signal_handler_pending_by_id(),
+ gtk_signal_add_emission_hook(), gtk_signal_add_emission_hook_full(),
+ gtk_signal_remove_emission_hook().
+ non-functional functions variants:
+ gtk_signal_add_emission_hook(), gtk_signal_remove_emission_hook().
+ the GtkCallbackMarshal argument to gtk_signal_connect_full() is
+ not supported anymore.
+ (gtk_signal_compat_matched): new internal function to aid
+ implementation of the compatibility macros, it provides
+ functionality to block/unblock/disconnect handlers based
+ on func/data.
+
+ * gtk/gtkenums.h: define GtkSignalRunType in terms of GSignalType,
+
+ * *.c: adaptions to new type registration API signatures.
+
+Fri Oct 20 15:26:33 2000 Tim Janik <timj@gtk.org>
+
+ * gtk/gtktypeutils.[hc]: removed G_TYPE_GTK_POINTER cludge.
+
2000-10-25 Robert Brady <robert@suse.co.uk>
* gdk/x11/gdkproperty-x11.c (gdk_property_get, gdk_property_change,
diff --git a/docs/Changes-2.0.txt b/docs/Changes-2.0.txt
index 437d73ffb..0cdca5a4e 100644
--- a/docs/Changes-2.0.txt
+++ b/docs/Changes-2.0.txt
@@ -106,6 +106,26 @@ Incompatible Changes from GTK+-1.2 to GTK+-1.4:
have to be moved into the ::destroy implementations. The reason for doing
this is that all object reference cycles should be broken at destruction
time.
+
+* Signal system changes:
+ The Gtk 2.0 signal merly proxies the GSignal system now.
+ For future usage, direct use of the GSignal API is recommended,
+ this avoids significant performance hits where GtkArg structures
+ have to be converted into GValues. For language bindings,
+ GSignal+GClosure provide a much more flexible and convenient
+ mechanism to hook into signal emissions or install class default
+ handlers, so the old GtkSignal API for language bindings is not
+ supported anymore.
+ Functions that got removed in the Gtk signal API:
+ gtk_signal_n_emissions(), gtk_signal_n_emissions_by_name(),
+ gtk_signal_set_funcs(), gtk_signal_handler_pending_by_id(),
+ gtk_signal_add_emission_hook(), gtk_signal_add_emission_hook_full(),
+ gtk_signal_remove_emission_hook(), gtk_signal_query().
+ gtk_signal_add_emission_hook(), gtk_signal_remove_emission_hook().
+ Also, the GtkCallbackMarshal argument to gtk_signal_connect_full() is
+ not supported anymore.
+ For many of the removed functions, similar variants are available
+ in the g_signal_* namespace.
- Inserting and deleting text in GtkEntry though functions such
as gtk_entry_insert_text() now leave the cursor at its original
diff --git a/docs/reference/Makefile.am b/docs/reference/Makefile.am
index 2cd7f681d..38a74371d 100644
--- a/docs/reference/Makefile.am
+++ b/docs/reference/Makefile.am
@@ -1,3 +1,3 @@
## Process this file with automake to produce Makefile.in
-SUBDIRS = gdk-pixbuf gdk gtk \ No newline at end of file
+#SUBDIRS = gdk-pixbuf gdk gtk
diff --git a/docs/reference/gdk-pixbuf/tmpl/animation.sgml b/docs/reference/gdk-pixbuf/tmpl/animation.sgml
index c8bff9b01..7a86308a2 100644
--- a/docs/reference/gdk-pixbuf/tmpl/animation.sgml
+++ b/docs/reference/gdk-pixbuf/tmpl/animation.sgml
@@ -18,147 +18,3 @@ Animations as multi-frame structures.
#GdkPixbufLoader
</para>
-<!-- ##### ENUM GdkPixbufFrameAction ##### -->
- <para>
- Each animation frame can have several things happen to it when the
- next frame is displayed. The #GdkPixbufFrameAction determines
- this. These are essentially the overlay modes supported by GIF
- animations.
- </para>
-
-@GDK_PIXBUF_FRAME_RETAIN: The previous image should remain displayed,
-and will potentially be occluded by the new frame.
-@GDK_PIXBUF_FRAME_DISPOSE: The animation will be reverted to the state
-before the frame was shown.
-@GDK_PIXBUF_FRAME_REVERT: The animation will be reverted to the first
-frame.
-
-<!-- ##### STRUCT GdkPixbufFrame ##### -->
- <para>
- This structure describes a frame in a #GdkPixbufAnimation. Each
- frame consists of a #GdkPixbuf, an offset of the frame within the
- animation's bounding box, a duration, and an overlay mode or
- action.
- </para>
-
-
-<!-- ##### STRUCT GdkPixbufAnimation ##### -->
- <para>
- This structure describes an animation, which is represented as a
- list of #GdkPixbufFrame structures.
- </para>
-
-
-<!-- ##### FUNCTION gdk_pixbuf_animation_new_from_file ##### -->
-<para>
-
-</para>
-
-@filename:
-@error:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_animation_ref ##### -->
-<para>
-
-</para>
-
-@animation:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_animation_unref ##### -->
-<para>
-
-</para>
-
-@animation:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_animation_get_frames ##### -->
-<para>
-
-</para>
-
-@animation:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_animation_get_width ##### -->
-<para>
-
-</para>
-
-@animation:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_animation_get_num_frames ##### -->
-<para>
-
-</para>
-
-@animation:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_animation_get_height ##### -->
-<para>
-
-</para>
-
-@animation:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_frame_get_pixbuf ##### -->
-<para>
-
-</para>
-
-@frame:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_frame_get_action ##### -->
-<para>
-
-</para>
-
-@frame:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_frame_get_y_offset ##### -->
-<para>
-
-</para>
-
-@frame:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_frame_get_delay_time ##### -->
-<para>
-
-</para>
-
-@frame:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_frame_get_x_offset ##### -->
-<para>
-
-</para>
-
-@frame:
-@Returns: <!--
-Local variables:
-mode: sgml
-sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
-End:
--->
-
-
diff --git a/docs/reference/gdk-pixbuf/tmpl/creating.sgml b/docs/reference/gdk-pixbuf/tmpl/creating.sgml
index b98b4024f..72ca320a1 100644
--- a/docs/reference/gdk-pixbuf/tmpl/creating.sgml
+++ b/docs/reference/gdk-pixbuf/tmpl/creating.sgml
@@ -43,68 +43,3 @@ Creating a pixbuf from image data that is already in memory.
gdk_pixbuf_finalize().
</para>
-<!-- ##### FUNCTION gdk_pixbuf_new ##### -->
-<para>
-
-</para>
-
-@colorspace:
-@has_alpha:
-@bits_per_sample:
-@width:
-@height:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_new_from_data ##### -->
-<para>
-
-</para>
-
-@data:
-@colorspace:
-@has_alpha:
-@bits_per_sample:
-@width:
-@height:
-@rowstride:
-@destroy_fn:
-@destroy_fn_data:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_new_from_xpm_data ##### -->
-<para>
-
-</para>
-
-@data:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_new_from_inline ##### -->
-<para>
-
-</para>
-
-@inline_pixbuf:
-@copy_pixels:
-@length:
-@error:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_copy ##### -->
-<para>
-
-</para>
-
-@pixbuf:
-@Returns: <!--
-Local variables:
-mode: sgml
-sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
-End:
--->
-
-
diff --git a/docs/reference/gdk-pixbuf/tmpl/file-loading.sgml b/docs/reference/gdk-pixbuf/tmpl/file-loading.sgml
index 7025c7edd..149903b43 100644
--- a/docs/reference/gdk-pixbuf/tmpl/file-loading.sgml
+++ b/docs/reference/gdk-pixbuf/tmpl/file-loading.sgml
@@ -25,18 +25,3 @@ Loading a pixbuf from a file.
#GdkPixbufLoader.
</para>
-<!-- ##### FUNCTION gdk_pixbuf_new_from_file ##### -->
-<para>
-
-</para>
-
-@filename:
-@error:
-@Returns: <!--
-Local variables:
-mode: sgml
-sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
-End:
--->
-
-
diff --git a/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-unused.sgml b/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-unused.sgml
index 456531628..41b1751d2 100644
--- a/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-unused.sgml
+++ b/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-unused.sgml
@@ -1,102 +1,9 @@
-<!-- ##### USER_FUNCTION GdkPixbufLastUnref ##### -->
- <para>
- A function of this type can be used to override the default
- operation when a pixbuf loses its last reference, i.e. when
- gdk_pixbuf_unref() is called on a #GdkPixbuf structure that has a
- reference count of 1. This function should determine whether to
- finalize the pixbuf by calling gdk_pixbuf_finalize(), or whether
- to just resume normal execution. The last unref handler for a
- #GdkPixbuf can be set using the
- gdk_pixbuf_set_last_unref_handler() function. By default, pixbufs
- will be finalized automatically if no last unref handler has been
- defined.
- </para>
-
-@pixbuf: The pixbuf that is losing its last reference.
-@data: User closure data.
-
-<!-- ##### SECTION ./tmpl/from-drawables.sgml:Title ##### -->
-Drawables to Pixbufs
-
-
-<!-- ##### ARG GnomeCanvasPixbuf:height_pixels ##### -->
-<para>
-
-</para>
-
-
-<!-- ##### SECTION ./tmpl/rendering.sgml:See_Also ##### -->
- <para>
- GdkRGB
- </para>
-
-
-<!-- ##### SECTION ./tmpl/xlib-from-drawables.sgml:Title ##### -->
-X Drawables to Pixbufs
-
-
-<!-- ##### FUNCTION gdk_pixbuf_render_pixmap_and_mask ##### -->
-<para>
-
-</para>
-
-@pixbuf:
-@pixmap_return:
-@mask_return:
-@alpha_threshold: <!--
-Local variables:
-mode: sgml
-sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
-End:
--->
-
-<!-- ##### ARG GnomeCanvasPixbuf:width ##### -->
- <para>
- Indicates the width the pixbuf will be scaled to. This argument
- will only be used if the <link
- linkend="GnomeCanvasPixbuf--width-set">width_set</link> argument
- is %TRUE. If the <link
- linkend="GnomeCanvasPixbuf--width-in-pixels">width_in_pixels</link>
- argument is %FALSE, the width will be taken to be in canvas units,
- and thus will be scaled along with the canvas item's affine
- transformation. If width_in_pixels is %TRUE, the width will be
- taken to be in pixels, and will visually remain a constant size
- even if the item's affine transformation changes.
- </para>
-
-
-<!-- ##### FUNCTION gdk_pixbuf_render_to_drawable ##### -->
+<!-- ##### FUNCTION gdk_pixbuf_get_rowstride ##### -->
<para>
</para>
@pixbuf:
-@drawable:
-@gc:
-@src_x:
-@src_y:
-@dest_x:
-@dest_y:
-@width:
-@height:
-@dither:
-@x_dither:
-@y_dither:
-
-<!-- ##### FUNCTION gdk_pixbuf_get_from_drawable ##### -->
-<para>
-
-</para>
-
-@dest:
-@src:
-@cmap:
-@src_x:
-@src_y:
-@dest_x:
-@dest_y:
-@width:
-@height:
@Returns: <!--
Local variables:
mode: sgml
@@ -104,104 +11,56 @@ sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
End:
-->
-<!-- ##### ARG GnomeCanvasPixbuf:x ##### -->
- <para>
- Indicates the horizontal translation offset of the pixbuf item's
- image. This offset may not actually appear horizontal, since it
- will be affected by the item's affine transformation. The default
- is 0.0.
- </para>
-
-
-<!-- ##### ARG GnomeCanvasPixbuf:y ##### -->
+<!-- ##### ARG GnomeCanvasPixbuf:width_in_pixels ##### -->
<para>
- Indicates the vertical translation offset of the pixbuf item's
- image. Works in the same way as the <link
- linkend="GnomeCanvasPixbuf--x">x</link> argument. The default is
- 0.0.
+ If this argument is %TRUE, then the width of the pixbuf will be
+ considered to be in pixels, that is, it will not be visually
+ scaled even if the item's affine transformation changes. If this
+ is %FALSE, then the width of the pixbuf will be considered to be
+ in canvas units, and so will be scaled normally by affine
+ transformations. The default is %FALSE.
</para>
-<!-- ##### SECTION ./tmpl/xlib-init.sgml:Short_Description ##### -->
-Initializing the &gdk-pixbuf; Xlib library.
-
-
-<!-- ##### SECTION ./tmpl/xlib-from-drawables.sgml:Long_Description ##### -->
- <para>
- The functions in this section allow you to take the image data
- from an X drawable and dump it into a #GdkPixbuf. This can be
- used for screenshots and other special effects. Note that these
- operations can be expensive, since the image data has to be
- transferred from the X server to the client program and converted.
- </para>
-
+<!-- ##### SECTION ./tmpl/xlib-rgb.sgml:See_Also ##### -->
<para>
- These functions are analogous to those for the Gdk version of
- &gdk-pixbuf;.
+ GdkRGB
</para>
-<!-- ##### FUNCTION gdk_pixbuf_new_from_art_pixbuf ##### -->
+<!-- ##### FUNCTION gdk_pixbuf_load_module ##### -->
<para>
</para>
-@art_pixbuf:
+@image_module:
+@error:
@Returns:
-<!-- ##### SECTION ./tmpl/xlib-init.sgml:See_Also ##### -->
- <para>
- XlibRGB
- </para>
-
-
-<!-- ##### ARG GnomeCanvasPixbuf:y_in_pixels ##### -->
- <para>
- Works in the same way as the <link
- linkend="GnomeCanvasPixbuf--x-in-pixels">x_in_pixels</link>
- argument, but controls whether the <link
- linkend="GnomeCanvasPixbuf--y">y</link> translation offset is
- scaled or not. The default is %FALSE.
- </para>
-
-<!--
-Local variables:
-mode: sgml
-sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
-End:
--->
-
-
<!-- ##### SECTION ./tmpl/gnome-canvas-pixbuf.sgml:See_Also ##### -->
<para>
#GnomeCanvas, #GdkPixbuf
</para>
-<!-- ##### ARG GnomeCanvasPixbuf:pixbuf ##### -->
- <para>
- Contains a pointer to a #GdkPixbuf structure that will be used by
- the pixbuf canvas item as an image source. When a pixbuf is set
- its reference count is incremented; if the pixbuf item kept a
- pointer to another #GdkPixbuf structure, the reference count of
- this structure will be decremented. Also, the GdkPixbuf's
- reference count will automatically be decremented when the
- #GnomeCanvasPixbuf item is destroyed. When a pixbuf is queried, a
- reference count will not be added to the return value; you must do
- this yourself if you intend to keep the pixbuf structure around.
- </para>
+<!-- ##### SECTION ./tmpl/gdk-pixbuf-io.sgml:Short_Description ##### -->
-<!-- ##### ARG GnomeCanvasPixbuf:y_pixels ##### -->
+
+<!-- ##### ENUM GdkPixbufError ##### -->
<para>
</para>
+@GDK_PIXBUF_ERROR_CORRUPT_IMAGE:
+@GDK_PIXBUF_ERROR_INSUFFICIENT_MEMORY:
+@GDK_PIXBUF_ERROR_BAD_OPTION_VALUE:
+@GDK_PIXBUF_ERROR_UNKNOWN_TYPE:
+@GDK_PIXBUF_ERROR_UNSUPPORTED_OPERATION:
+@GDK_PIXBUF_ERROR_FAILED:
-<!-- ##### SECTION ./tmpl/xlib-rgb.sgml:See_Also ##### -->
- <para>
- GdkRGB
- </para>
+<!-- ##### SECTION ./tmpl/gnome-canvas-pixbuf.sgml:Short_Description ##### -->
+Canvas item to display #GdkPixbuf images.
<!-- ##### SECTION ./tmpl/xlib-rendering.sgml:Long_Description ##### -->
@@ -217,132 +76,81 @@ End:
</para>
-<!-- ##### SECTION ./tmpl/gdk-pixbuf-io.sgml:Short_Description ##### -->
-
-
-
-<!-- ##### SECTION ./tmpl/gnome-canvas-pixbuf.sgml:Short_Description ##### -->
-Canvas item to display #GdkPixbuf images.
-
+<!-- ##### FUNCTION gdk_pixbuf_render_threshold_alpha ##### -->
+<para>
-<!-- ##### ARG GnomeCanvasPixbuf:x_in_pixels ##### -->
- <para>
- If this argument is %TRUE, the pixbuf's translation with respect
- to its logical origin in item-relative coordinates will be in
- pixels, that is, the visible offset will not change even if the
- item's affine transformation changes. If it is %FALSE, the
- pixbuf's translation will be taken to be in canvas units, and thus
- will change along with the item's affine transformation. The
- default is %FALSE.
- </para>
+</para>
+@pixbuf:
+@bitmap:
+@src_x:
+@src_y:
+@dest_x:
+@dest_y:
+@width:
+@height:
+@alpha_threshold:
-<!-- ##### SECTION ./tmpl/from-drawables.sgml:Long_Description ##### -->
+<!-- ##### SECTION ./tmpl/rendering.sgml:Long_Description ##### -->
<para>
- The functions in this section allow you to take the image data
- from a GDK drawable and dump it into a #GdkPixbuf. This can be
- used for screenshots and other special effects. Note that these
- operations can be expensive, since the image data has to be
- transferred from the X server to the client program and converted.
+ The &gdk-pixbuf; library provides several convenience functions to
+ render pixbufs to GDK drawables. It uses the GdkRGB to render the
+ image data.
</para>
-
-<!-- ##### SECTION ./tmpl/xlib-rgb.sgml:Long_Description ##### -->
<para>
- The XlibRGB set of functions is a port of the GdkRGB library to
- use plain Xlib and X drawables. You can use these functions to
- render RGB buffers into drawables very quickly with high-quality
- dithering.
+ At this point there is not a standard alpha channel extension for
+ the X Window System, so it is not possible to use full opacity
+ information when painting images to arbitrary drawables. The
+ &gdk-pixbuf; convenience functions will threshold the opacity
+ information to create a bi-level clipping mask (black and white),
+ and use that to draw the image onto a drawable.
</para>
-
-<!-- ##### SECTION ./tmpl/xlib-rgb.sgml:Short_Description ##### -->
-Functions for rendering RGB buffers to X drawables.
+ <important>
+ <para>
+ Since these functions use GdkRGB for rendering, you must
+ initialize GdkRGB before using any of them. You can do this by
+ calling gdk_rgb_init() near the beginning of your program.
+ </para>
+ </important>
-<!-- ##### MACRO GNOME_CANVAS_PIXBUF ##### -->
- <para>
- Casts a #GtkOjbect to a #GnomeCanvasPixbuf.
- </para>
+<!-- ##### SECTION ./tmpl/xlib-init.sgml:Title ##### -->
+&gdk-pixbuf; Xlib initialization
-@obj: A GTK+ object.
-<!-- ##### SECTION ./tmpl/gdk-pixbuf-io.sgml:See_Also ##### -->
+<!-- ##### FUNCTION gdk_pixbuf_saturate_and_pixelate ##### -->
<para>
</para>
+@src:
+@dest:
+@saturation:
+@pixelate:
-<!-- ##### SECTION ./tmpl/xlib-rendering.sgml:Short_Description ##### -->
-Rendering a pixbuf to an X drawable.
-
-
-<!-- ##### FUNCTION gdk_pixbuf_finalize ##### -->
+<!-- ##### FUNCTION gdk_pixbuf_get_height ##### -->
<para>
</para>
-@pixbuf: <!--
-Local variables:
-mode: sgml
-sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
-End:
--->
-
-<!-- ##### SECTION ./tmpl/rendering.sgml:Short_Description ##### -->
-Rendering a pixbuf to a GDK drawable.
-
+@pixbuf:
+@Returns:
-<!-- ##### FUNCTION gdk_pixbuf_set_last_unref_handler ##### -->
+<!-- ##### FUNCTION gdk_pixbuf_get_bits_per_sample ##### -->
<para>
</para>
@pixbuf:
-@last_unref_fn:
-@last_unref_fn_data:
-
-<!-- ##### ARG GnomeCanvasPixbuf:x_set ##### -->
- <para>
- Determines whether the <link
- linkend="GnomeCanvasPixbuf--x">x</link> argument is used to
- translate the pixbuf from its logical origin in item-relative
- coordinates.
- </para>
-
-
-<!-- ##### ARG GnomeCanvasPixbuf:width_in_pixels ##### -->
- <para>
- If this argument is %TRUE, then the width of the pixbuf will be
- considered to be in pixels, that is, it will not be visually
- scaled even if the item's affine transformation changes. If this
- is %FALSE, then the width of the pixbuf will be considered to be
- in canvas units, and so will be scaled normally by affine
- transformations. The default is %FALSE.
- </para>
-
-
-<!-- ##### SECTION ./tmpl/xlib-init.sgml:Long_Description ##### -->
- <para>
- In addition to the normal Gdk-specific functions, the &gdk-pixbuf;
- package provides a small library that lets Xlib-only applications
- use #GdkPixbuf structures and render them to X drawables. The
- functions in this section are used to initialize the &gdk-pixbuf;
- Xlib library. This library must be initialized near the beginning
- or the program or before calling any of the other &gdk-pixbuf;
- Xlib functions; it cannot be initialized automatically since
- Xlib-only applications do not call gdk_rgb_init() like GNOME
- applications do.
- </para>
-
+@Returns:
-<!-- ##### FUNCTION gdk_pixbuf_get_format ##### -->
+<!-- ##### MACRO GDK_PIXBUF_MAJOR ##### -->
<para>
</para>
-@pixbuf:
-@Returns:
<!-- ##### ARG GnomeCanvasPixbuf:height_in_pixels ##### -->
<para>
@@ -352,167 +160,248 @@ Rendering a pixbuf to a GDK drawable.
</para>
-<!-- ##### SECTION ./tmpl/xlib-rendering.sgml:See_Also ##### -->
+<!-- ##### FUNCTION gdk_pixbuf_animation_get_frames ##### -->
<para>
</para>
+@animation:
+@Returns:
-<!-- ##### ARG GnomeCanvasPixbuf:width_set ##### -->
- <para>
- Determines whether the <link
- linkend="GnomeCanvasPixbuf--width">width</link> argument is taken
- into account when scaling the pixbuf item. If this argument is
- %FALSE, then the width value of the pixbuf will be used instead.
- This argument is %FALSE by default.
- </para>
+<!-- ##### FUNCTION gdk_pixbuf_animation_get_width ##### -->
+<para>
+</para>
-<!-- ##### FUNCTION gdk_pixbuf_render_to_drawable_alpha ##### -->
+@animation:
+@Returns:
+
+<!-- ##### SECTION ./tmpl/xlib-from-drawables.sgml:See_Also ##### -->
<para>
</para>
-@pixbuf:
-@drawable:
-@src_x:
-@src_y:
-@dest_x:
-@dest_y:
-@width:
-@height:
-@alpha_mode:
-@alpha_threshold:
-@dither:
-@x_dither:
-@y_dither:
-<!-- ##### SECTION ./tmpl/xlib-init.sgml:Title ##### -->
-&gdk-pixbuf; Xlib initialization
+<!-- ##### SECTION ./tmpl/rendering.sgml:Title ##### -->
+Rendering
+
+
+<!-- ##### MACRO GDK_PIXBUF_MINOR ##### -->
+<para>
+
+</para>
<!-- ##### SECTION ./tmpl/xlib-from-drawables.sgml:Short_Description ##### -->
Getting parts of an X drawable's image data into a pixbuf.
-<!-- ##### SECTION ./tmpl/xlib-rgb.sgml:Title ##### -->
-XlibRGB
+<!-- ##### STRUCT GdkPixbufModule ##### -->
+<para>
+</para>
-<!-- ##### ARG GnomeCanvasPixbuf:x_pixels ##### -->
+@module_name:
+@format_check:
+@module:
+@load:
+@load_xpm_data:
+@begin_load:
+@stop_load:
+@load_increment:
+@load_animation:
+@save:
+
+<!-- ##### FUNCTION gdk_pixbuf_get_colorspace ##### -->
<para>
</para>
+@pixbuf:
+@Returns:
-<!-- ##### ARG GnomeCanvasPixbuf:height ##### -->
- <para>
- Indicates the height the pixbuf will be scaled to. This argument
- will only be used if the <link
- linkend="GnomeCanvasPixbuf--height-set">height_set</link> argument
- is %TRUE. Works in the same way as the <link
- linkend="GnomeCanvasPixbuf--width">width</link> argument.
- </para>
+<!-- ##### FUNCTION gdk_pixbuf_animation_get_num_frames ##### -->
+<para>
+</para>
-<!-- ##### SECTION ./tmpl/xlib-from-drawables.sgml:See_Also ##### -->
+@animation:
+@Returns:
+
+<!-- ##### SECTION ./tmpl/from-drawables.sgml:Short_Description ##### -->
+Getting parts of a drawable's image data into a pixbuf.
+
+
+<!-- ##### FUNCTION gdk_pixbuf_render_pixmap_and_mask ##### -->
<para>
</para>
+@pixbuf:
+@pixmap_return:
+@mask_return:
+@alpha_threshold: <!--
+Local variables:
+mode: sgml
+sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
+End:
+-->
-<!-- ##### SECTION ./tmpl/from-drawables.sgml:See_Also ##### -->
- <para>
- gdk_image_get().
- </para>
+<!-- ##### FUNCTION gdk_pixbuf_composite_color ##### -->
+<para>
+</para>
-<!-- ##### STRUCT GdkPixbufAnimationClass ##### -->
+@src:
+@dest:
+@dest_x:
+@dest_y:
+@dest_width:
+@dest_height:
+@offset_x:
+@offset_y:
+@scale_x:
+@scale_y:
+@interp_type:
+@overall_alpha:
+@check_x:
+@check_y:
+@check_size:
+@color1:
+@color2:
+
+<!-- ##### FUNCTION gdk_pixbuf_new_from_data ##### -->
<para>
</para>
+@data:
+@colorspace:
+@has_alpha:
+@bits_per_sample:
+@width:
+@height:
+@rowstride:
+@destroy_fn:
+@destroy_fn_data:
+@Returns:
-<!-- ##### SECTION ./tmpl/rendering.sgml:Title ##### -->
-Rendering
-
+<!-- ##### FUNCTION gdk_pixbuf_animation_new_from_file ##### -->
+<para>
-<!-- ##### SECTION ./tmpl/gnome-canvas-pixbuf.sgml:Title ##### -->
-GnomeCanvasPixbuf
+</para>
+@filename:
+@error:
+@Returns:
-<!-- ##### MACRO GDK_PIXBUF_LOADER ##### -->
+<!-- ##### ARG GnomeCanvasPixbuf:y_in_pixels ##### -->
<para>
- Casts a #GtkObject to a #GdkPixbufLoader.
+ Works in the same way as the <link
+ linkend="GnomeCanvasPixbuf--x-in-pixels">x_in_pixels</link>
+ argument, but controls whether the <link
+ linkend="GnomeCanvasPixbuf--y">y</link> translation offset is
+ scaled or not. The default is %FALSE.
</para>
-@obj: A GTK+ object.
+<!--
+Local variables:
+mode: sgml
+sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
+End:
+-->
-<!-- ##### ARG GnomeCanvasPixbuf:y_set ##### -->
+
+<!-- ##### STRUCT GdkPixbufAnimation ##### -->
<para>
- Determines whether the <link
- linkend="GnomeCanvasPixbuf--y">y</link> argument is used to
- translate the pixbuf from its logical origin in item-relative
- coordinates. Works in the same way as the <link
- linkend="GnomeCanvasPixbuf--x-set">x_set</link> argument. The
- default is %FALSE.
+ This structure describes an animation, which is represented as a
+ list of #GdkPixbufFrame structures.
</para>
-<!-- ##### SECTION ./tmpl/rendering.sgml:Long_Description ##### -->
- <para>
- The &gdk-pixbuf; library provides several convenience functions to
- render pixbufs to GDK drawables. It uses the GdkRGB to render the
- image data.
- </para>
+<!-- ##### SECTION ./tmpl/xlib-init.sgml:Short_Description ##### -->
+Initializing the &gdk-pixbuf; Xlib library.
- <para>
- At this point there is not a standard alpha channel extension for
- the X Window System, so it is not possible to use full opacity
- information when painting images to arbitrary drawables. The
- &gdk-pixbuf; convenience functions will threshold the opacity
- information to create a bi-level clipping mask (black and white),
- and use that to draw the image onto a drawable.
- </para>
- <important>
- <para>
- Since these functions use GdkRGB for rendering, you must
- initialize GdkRGB before using any of them. You can do this by
- calling gdk_rgb_init() near the beginning of your program.
- </para>
- </important>
+<!-- ##### FUNCTION gdk_pixbuf_frame_get_delay_time ##### -->
+<para>
+</para>
-<!-- ##### SECTION ./tmpl/from-drawables.sgml:Short_Description ##### -->
-Getting parts of a drawable's image data into a pixbuf.
+@frame:
+@Returns:
+<!-- ##### ENUM GdkInterpType ##### -->
+ <para>
+ This enumeration describes the different interpolation modes that
+ can be used with the scaling functions.
+
+ <note>
+ <para>
+ Cubic filtering is missing from the list; hyperbolic
+ interpolation is just as fast and results in higher quality.
+ </para>
+ </note>
+ </para>
-<!-- ##### FUNCTION gdk_pixbuf_render_threshold_alpha ##### -->
+@GDK_INTERP_NEAREST: Nearest neighbor sampling; this is the fastest
+and lowest quality mode.
+@GDK_INTERP_TILES: This is an accurate simulation of the PostScript
+image operator without any interpolation enabled. Each pixel is
+rendered as a tiny parallelogram of solid color, the edges of which
+are implemented with antialiasing. It resembles nearest neighbor for
+enlargement, and bilinear for reduction.
+@GDK_INTERP_BILINEAR: Bilinear interpolation. For enlargement, it is
+equivalent to point-sampling the ideal bilinear-interpolated image.
+For reduction, it is equivalent to laying down small tiles and
+integrating over the coverage area.
+@GDK_INTERP_HYPER: This is the slowest and highest quality
+reconstruction function. It is derived from the hyperbolic filters in
+Wolberg's "Digital Image Warping", and is formally defined as the
+hyperbolic-filter sampling the ideal hyperbolic-filter interpolated
+image (the filter is designed to be idempotent for 1:1 pixel mapping).
+
+<!-- ##### FUNCTION gdk_pixbuf_render_to_drawable_alpha ##### -->
<para>
</para>
@pixbuf:
-@bitmap:
+@drawable:
@src_x:
@src_y:
@dest_x:
@dest_y:
@width:
@height:
+@alpha_mode:
@alpha_threshold:
+@dither:
+@x_dither:
+@y_dither:
-<!-- ##### ARG GnomeCanvasPixbuf:width_pixels ##### -->
-<para>
-
-</para>
-
+<!-- ##### ENUM GdkPixbufFrameAction ##### -->
+ <para>
+ Each animation frame can have several things happen to it when the
+ next frame is displayed. The #GdkPixbufFrameAction determines
+ this. These are essentially the overlay modes supported by GIF
+ animations.
+ </para>
-<!-- ##### STRUCT GdkPixbufClass ##### -->
-<para>
+@GDK_PIXBUF_FRAME_RETAIN: The previous image should remain displayed,
+and will potentially be occluded by the new frame.
+@GDK_PIXBUF_FRAME_DISPOSE: The animation will be reverted to the state
+before the frame was shown.
+@GDK_PIXBUF_FRAME_REVERT: The animation will be reverted to the first
+frame.
-</para>
+<!-- ##### SECTION ./tmpl/xlib-rgb.sgml:Long_Description ##### -->
+ <para>
+ The XlibRGB set of functions is a port of the GdkRGB library to
+ use plain Xlib and X drawables. You can use these functions to
+ render RGB buffers into drawables very quickly with high-quality
+ dithering.
+ </para>
<!-- ##### SECTION ./tmpl/gnome-canvas-pixbuf.sgml:Long_Description ##### -->
@@ -684,16 +573,407 @@ Getting parts of a drawable's image data into a pixbuf.
</refsect2>
-<!-- ##### SECTION ./tmpl/gdk-pixbuf-io.sgml:Long_Description ##### -->
+<!-- ##### SECTION ./tmpl/rendering.sgml:Short_Description ##### -->
+Rendering a pixbuf to a GDK drawable.
+
+
+<!-- ##### MACRO GDK_PIXBUF_LOADER ##### -->
+ <para>
+ Casts a #GtkObject to a #GdkPixbufLoader.
+ </para>
+
+@obj: A GTK+ object.
+
+<!-- ##### STRUCT GdkPixbufAnimationClass ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### ARG GnomeCanvasPixbuf:x_set ##### -->
+ <para>
+ Determines whether the <link
+ linkend="GnomeCanvasPixbuf--x">x</link> argument is used to
+ translate the pixbuf from its logical origin in item-relative
+ coordinates.
+ </para>
+
+
+<!-- ##### USER_FUNCTION ModulePreparedNotifyFunc ##### -->
+<para>
+
+</para>
+
+@pixbuf:
+@user_data:
+
+<!-- ##### MACRO GNOME_CANVAS_PIXBUF ##### -->
+ <para>
+ Casts a #GtkOjbect to a #GnomeCanvasPixbuf.
+ </para>
+
+@obj: A GTK+ object.
+
+<!-- ##### FUNCTION gdk_pixbuf_ref ##### -->
+ <para>
+
+ </para>
+
+@pixbuf:
+@Returns:
+
+<!-- ##### FUNCTION gdk_pixbuf_get_width ##### -->
+<para>
+
+</para>
+
+@pixbuf:
+@Returns:
+
+<!-- ##### ENUM GdkColorspace ##### -->
+ <para>
+ This enumeration defines the color spaces that are supported by
+ the &gdk-pixbuf; library. Currently only RGB is supported.
+ </para>
+
+@GDK_COLORSPACE_RGB: Indicates a red/green/blue additive color space.
+
+<!-- ##### ARG GnomeCanvasPixbuf:width_set ##### -->
+ <para>
+ Determines whether the <link
+ linkend="GnomeCanvasPixbuf--width">width</link> argument is taken
+ into account when scaling the pixbuf item. If this argument is
+ %FALSE, then the width value of the pixbuf will be used instead.
+ This argument is %FALSE by default.
+ </para>
+
+
+<!-- ##### FUNCTION gdk_pixbuf_get_module ##### -->
+<para>
+
+</para>
+
+@buffer:
+@size:
+@filename:
+@error:
+@Returns:
+
+<!-- ##### SECTION ./tmpl/xlib-from-drawables.sgml:Long_Description ##### -->
+ <para>
+ The functions in this section allow you to take the image data
+ from an X drawable and dump it into a #GdkPixbuf. This can be
+ used for screenshots and other special effects. Note that these
+ operations can be expensive, since the image data has to be
+ transferred from the X server to the client program and converted.
+ </para>
+
+ <para>
+ These functions are analogous to those for the Gdk version of
+ &gdk-pixbuf;.
+ </para>
+
+
+<!-- ##### FUNCTION gdk_pixbuf_get_named_module ##### -->
+<para>
+
+</para>
+
+@name:
+@error:
+@Returns:
+
+<!-- ##### FUNCTION gdk_pixbuf_new ##### -->
+<para>
+
+</para>
+
+@colorspace:
+@has_alpha:
+@bits_per_sample:
+@width:
+@height:
+@Returns:
+
+<!-- ##### USER_FUNCTION GdkPixbufLastUnref ##### -->
+ <para>
+ A function of this type can be used to override the default
+ operation when a pixbuf loses its last reference, i.e. when
+ gdk_pixbuf_unref() is called on a #GdkPixbuf structure that has a
+ reference count of 1. This function should determine whether to
+ finalize the pixbuf by calling gdk_pixbuf_finalize(), or whether
+ to just resume normal execution. The last unref handler for a
+ #GdkPixbuf can be set using the
+ gdk_pixbuf_set_last_unref_handler() function. By default, pixbufs
+ will be finalized automatically if no last unref handler has been
+ defined.
+ </para>
+
+@pixbuf: The pixbuf that is losing its last reference.
+@data: User closure data.
+
+<!-- ##### FUNCTION gdk_pixbuf_new_from_inline ##### -->
+<para>
+
+</para>
+
+@inline_pixbuf:
+@copy_pixels:
+@length:
+@error:
+@Returns:
+
+<!-- ##### SECTION ./tmpl/xlib-init.sgml:See_Also ##### -->
+ <para>
+ XlibRGB
+ </para>
+
+
+<!-- ##### FUNCTION gdk_pixbuf_unref ##### -->
+<para>
+
+</para>
+
+@pixbuf:
+
+<!-- ##### FUNCTION gdk_pixbuf_get_has_alpha ##### -->
+<para>
+
+</para>
+
+@pixbuf:
+@Returns:
+
+<!-- ##### SECTION ./tmpl/gdk-pixbuf-io.sgml:See_Also ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### USER_FUNCTION GdkPixbufDestroyNotify ##### -->
+ <para>
+ A function of this type is responsible for freeing the pixel array
+ of a pixbuf. The gdk_pixbuf_new_from_data() function lets you
+ pass in a pre-allocated pixel array so that a pixbuf can be
+ created from it; in this case you will need to pass in a function
+ of #GdkPixbufDestroyNotify so that the pixel data can be freed
+ when the pixbuf is finalized.
+ </para>
+
+@pixels: The pixel array of the pixbuf that is being finalized.
+@data: User closure data.
+
+<!-- ##### MACRO GDK_PIXBUF_ERROR ##### -->
<para>
</para>
+<!-- ##### FUNCTION gdk_pixbuf_new_from_xpm_data ##### -->
+<para>
+
+</para>
+
+@data:
+@Returns:
+
+<!-- ##### FUNCTION gdk_pixbuf_new_from_art_pixbuf ##### -->
+<para>
+
+</para>
+
+@art_pixbuf:
+@Returns:
+
+<!-- ##### FUNCTION gdk_pixbuf_scale_simple ##### -->
+<para>
+
+</para>
+
+@src:
+@dest_width:
+@dest_height:
+@interp_type:
+@Returns:
+
+<!-- ##### ARG GnomeCanvasPixbuf:height ##### -->
+ <para>
+ Indicates the height the pixbuf will be scaled to. This argument
+ will only be used if the <link
+ linkend="GnomeCanvasPixbuf--height-set">height_set</link> argument
+ is %TRUE. Works in the same way as the <link
+ linkend="GnomeCanvasPixbuf--width">width</link> argument.
+ </para>
+
+
+<!-- ##### FUNCTION gdk_pixbuf_composite ##### -->
+<para>
+
+</para>
+
+@src:
+@dest:
+@dest_x:
+@dest_y:
+@dest_width:
+@dest_height:
+@offset_x:
+@offset_y:
+@scale_x:
+@scale_y:
+@interp_type:
+@overall_alpha:
+
+<!-- ##### FUNCTION gdk_pixbuf_frame_get_pixbuf ##### -->
+<para>
+
+</para>
+
+@frame:
+@Returns:
+
+<!-- ##### FUNCTION gdk_pixbuf_get_n_channels ##### -->
+<para>
+
+</para>
+
+@pixbuf:
+@Returns:
+
<!-- ##### SECTION ./tmpl/xlib-rendering.sgml:Title ##### -->
Xlib Rendering
+<!-- ##### SECTION ./tmpl/from-drawables.sgml:See_Also ##### -->
+ <para>
+ gdk_image_get().
+ </para>
+
+
+<!-- ##### ARG GnomeCanvasPixbuf:height_pixels ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### ARG GnomeCanvasPixbuf:pixbuf ##### -->
+ <para>
+ Contains a pointer to a #GdkPixbuf structure that will be used by
+ the pixbuf canvas item as an image source. When a pixbuf is set
+ its reference count is incremented; if the pixbuf item kept a
+ pointer to another #GdkPixbuf structure, the reference count of
+ this structure will be decremented. Also, the GdkPixbuf's
+ reference count will automatically be decremented when the
+ #GnomeCanvasPixbuf item is destroyed. When a pixbuf is queried, a
+ reference count will not be added to the return value; you must do
+ this yourself if you intend to keep the pixbuf structure around.
+ </para>
+
+
+<!-- ##### FUNCTION gdk_pixbuf_frame_get_action ##### -->
+<para>
+
+</para>
+
+@frame:
+@Returns:
+
+<!-- ##### FUNCTION gdk_pixbuf_frame_get_y_offset ##### -->
+<para>
+
+</para>
+
+@frame:
+@Returns:
+
+<!-- ##### SECTION ./tmpl/xlib-rgb.sgml:Short_Description ##### -->
+Functions for rendering RGB buffers to X drawables.
+
+
+<!-- ##### ARG GnomeCanvasPixbuf:x ##### -->
+ <para>
+ Indicates the horizontal translation offset of the pixbuf item's
+ image. This offset may not actually appear horizontal, since it
+ will be affected by the item's affine transformation. The default
+ is 0.0.
+ </para>
+
+
+<!-- ##### ARG GnomeCanvasPixbuf:y ##### -->
+ <para>
+ Indicates the vertical translation offset of the pixbuf item's
+ image. Works in the same way as the <link
+ linkend="GnomeCanvasPixbuf--x">x</link> argument. The default is
+ 0.0.
+ </para>
+
+
+<!-- ##### FUNCTION gdk_pixbuf_animation_get_height ##### -->
+<para>
+
+</para>
+
+@animation:
+@Returns:
+
+<!-- ##### ARG GnomeCanvasPixbuf:width ##### -->
+ <para>
+ Indicates the width the pixbuf will be scaled to. This argument
+ will only be used if the <link
+ linkend="GnomeCanvasPixbuf--width-set">width_set</link> argument
+ is %TRUE. If the <link
+ linkend="GnomeCanvasPixbuf--width-in-pixels">width_in_pixels</link>
+ argument is %FALSE, the width will be taken to be in canvas units,
+ and thus will be scaled along with the canvas item's affine
+ transformation. If width_in_pixels is %TRUE, the width will be
+ taken to be in pixels, and will visually remain a constant size
+ even if the item's affine transformation changes.
+ </para>
+
+
+<!-- ##### FUNCTION gdk_pixbuf_composite_color_simple ##### -->
+<para>
+
+</para>
+
+@src:
+@dest_width:
+@dest_height:
+@interp_type:
+@overall_alpha:
+@check_size:
+@color1:
+@color2:
+@Returns: <!--
+Local variables:
+mode: sgml
+sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
+End:
+-->
+
+<!-- ##### MACRO GDK_PIXBUF_MICRO ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### FUNCTION gdk_pixbuf_preinit ##### -->
+<para>
+
+</para>
+
+@app:
+@modinfo:
+
+<!-- ##### FUNCTION gdk_pixbuf_set_last_unref_handler ##### -->
+<para>
+
+</para>
+
+@pixbuf:
+@last_unref_fn:
+@last_unref_fn_data:
+
<!-- ##### ARG GnomeCanvasPixbuf:height_set ##### -->
<para>
Determines whether the <link
@@ -705,7 +985,377 @@ Xlib Rendering
</para>
+<!-- ##### FUNCTION gdk_pixbuf_animation_unref ##### -->
+<para>
+
+</para>
+
+@animation:
+
+<!-- ##### FUNCTION gdk_pixbuf_render_to_drawable ##### -->
+<para>
+
+</para>
+
+@pixbuf:
+@drawable:
+@gc:
+@src_x:
+@src_y:
+@dest_x:
+@dest_y:
+@width:
+@height:
+@dither:
+@x_dither:
+@y_dither:
+
+<!-- ##### SECTION ./tmpl/xlib-init.sgml:Long_Description ##### -->
+ <para>
+ In addition to the normal Gdk-specific functions, the &gdk-pixbuf;
+ package provides a small library that lets Xlib-only applications
+ use #GdkPixbuf structures and render them to X drawables. The
+ functions in this section are used to initialize the &gdk-pixbuf;
+ Xlib library. This library must be initialized near the beginning
+ or the program or before calling any of the other &gdk-pixbuf;
+ Xlib functions; it cannot be initialized automatically since
+ Xlib-only applications do not call gdk_rgb_init() like GNOME
+ applications do.
+ </para>
+
+
+<!-- ##### ARG GnomeCanvasPixbuf:y_pixels ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### SECTION ./tmpl/xlib-rendering.sgml:See_Also ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### FUNCTION gdk_pixbuf_frame_get_x_offset ##### -->
+<para>
+
+</para>
+
+@frame:
+@Returns: <!--
+Local variables:
+mode: sgml
+sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
+End:
+-->
+
+<!-- ##### SECTION ./tmpl/gdk-pixbuf-io.sgml:Long_Description ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### SECTION ./tmpl/rendering.sgml:See_Also ##### -->
+ <para>
+ GdkRGB
+ </para>
+
+
+<!-- ##### SECTION ./tmpl/xlib-rendering.sgml:Short_Description ##### -->
+Rendering a pixbuf to an X drawable.
+
+
+<!-- ##### USER_FUNCTION ModuleUpdatedNotifyFunc ##### -->
+<para>
+
+</para>
+
+@pixbuf:
+@x:
+@y:
+@width:
+@height:
+@user_data:
+
+<!-- ##### FUNCTION gdk_pixbuf_finalize ##### -->
+<para>
+
+</para>
+
+@pixbuf: <!--
+Local variables:
+mode: sgml
+sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
+End:
+-->
+
+<!-- ##### FUNCTION gdk_pixbuf_get_pixels ##### -->
+<para>
+
+</para>
+
+@pixbuf:
+@Returns:
+
+<!-- ##### FUNCTION gdk_pixbuf_get_from_drawable ##### -->
+<para>
+
+</para>
+
+@dest:
+@src:
+@cmap:
+@src_x:
+@src_y:
+@dest_x:
+@dest_y:
+@width:
+@height:
+@Returns: <!--
+Local variables:
+mode: sgml
+sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
+End:
+-->
+
+<!-- ##### USER_FUNCTION ModuleFrameDoneNotifyFunc ##### -->
+<para>
+
+</para>
+
+@frame:
+@user_data:
+
+<!-- ##### FUNCTION gdk_pixbuf_postinit ##### -->
+<para>
+
+</para>
+
+@app:
+@modinfo:
+
<!-- ##### SECTION ./tmpl/gdk-pixbuf-io.sgml:Title ##### -->
gdk-pixbuf-io
+<!-- ##### FUNCTION gdk_pixbuf_copy ##### -->
+<para>
+
+</para>
+
+@pixbuf:
+@Returns: <!--
+Local variables:
+mode: sgml
+sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
+End:
+-->
+
+<!-- ##### ARG GnomeCanvasPixbuf:y_set ##### -->
+ <para>
+ Determines whether the <link
+ linkend="GnomeCanvasPixbuf--y">y</link> argument is used to
+ translate the pixbuf from its logical origin in item-relative
+ coordinates. Works in the same way as the <link
+ linkend="GnomeCanvasPixbuf--x-set">x_set</link> argument. The
+ default is %FALSE.
+ </para>
+
+
+<!-- ##### FUNCTION gdk_pixbuf_animation_ref ##### -->
+<para>
+
+</para>
+
+@animation:
+@Returns:
+
+<!-- ##### SECTION ./tmpl/gnome-canvas-pixbuf.sgml:Title ##### -->
+GnomeCanvasPixbuf
+
+
+<!-- ##### STRUCT GdkPixbuf ##### -->
+ <para>
+ This is the main structure in the &gdk-pixbuf; library. It is
+ used to represent images. It contains information about the
+ image's pixel data, its color space, bits per sample, width and
+ height, and the rowstride or number of bytes between rows.
+ </para>
+
+
+<!-- ##### ARG GnomeCanvasPixbuf:x_pixels ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### MACRO GDK_PIXBUF_VERSION ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### VARIABLE gdk_pixbuf_version ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### FUNCTION gdk_pixbuf_scale ##### -->
+<para>
+
+</para>
+
+@src:
+@dest:
+@dest_x:
+@dest_y:
+@dest_width:
+@dest_height:
+@offset_x:
+@offset_y:
+@scale_x:
+@scale_y:
+@interp_type:
+
+<!-- ##### FUNCTION gdk_pixbuf_get_format ##### -->
+<para>
+
+</para>
+
+@pixbuf:
+@Returns:
+
+<!-- ##### SECTION ./tmpl/from-drawables.sgml:Long_Description ##### -->
+ <para>
+ The functions in this section allow you to take the image data
+ from a GDK drawable and dump it into a #GdkPixbuf. This can be
+ used for screenshots and other special effects. Note that these
+ operations can be expensive, since the image data has to be
+ transferred from the X server to the client program and converted.
+ </para>
+
+
+<!-- ##### ARG GnomeCanvasPixbuf:width_pixels ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### ENUM GdkPixbufAlphaMode ##### -->
+ <para>
+ These values can be passed to
+ gdk_pixbuf_render_to_drawable_alpha() to control how the alpha
+ chanel of an image should be handled. This function can create a
+ bilevel clipping mask (black and white) and use it while painting
+ the image. In the future, when the X Window System gets an alpha
+ channel extension, it will be possible to do full alpha
+ compositing onto arbitrary drawables. For now both cases fall
+ back to a bilevel clipping mask.
+ </para>
+
+@GDK_PIXBUF_ALPHA_BILEVEL: A bilevel clipping mask (black and white)
+will be created and used to draw the image. Pixels below 0.5 opacity
+will be considered fully transparent, and all others will be
+considered fully opaque.
+@GDK_PIXBUF_ALPHA_FULL: For now falls back to #GDK_PIXBUF_ALPHA_BILEVEL.
+In the future it will do full alpha compositing.
+
+<!-- ##### STRUCT GdkPixbufFrame ##### -->
+ <para>
+ This structure describes a frame in a #GdkPixbufAnimation. Each
+ frame consists of a #GdkPixbuf, an offset of the frame within the
+ animation's bounding box, a duration, and an overlay mode or
+ action.
+ </para>
+
+
+<!-- ##### FUNCTION gdk_pixbuf_add_alpha ##### -->
+<para>
+
+</para>
+
+@pixbuf:
+@substitute_color:
+@r:
+@g:
+@b:
+@Returns:
+
+<!-- ##### USER_FUNCTION ModuleAnimationDoneNotifyFunc ##### -->
+<para>
+
+</para>
+
+@pixbuf:
+@user_data:
+
+<!-- ##### FUNCTION gdk_pixbuf_copy_area ##### -->
+<para>
+
+</para>
+
+@src_pixbuf:
+@src_x:
+@src_y:
+@width:
+@height:
+@dest_pixbuf:
+@dest_x:
+@dest_y: <!--
+Local variables:
+mode: sgml
+sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
+End:
+-->
+
+<!-- ##### FUNCTION gdk_pixbuf_init ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### SECTION ./tmpl/xlib-from-drawables.sgml:Title ##### -->
+X Drawables to Pixbufs
+
+
+<!-- ##### STRUCT GdkPixbufClass ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### SECTION ./tmpl/from-drawables.sgml:Title ##### -->
+Drawables to Pixbufs
+
+
+<!-- ##### ARG GnomeCanvasPixbuf:x_in_pixels ##### -->
+ <para>
+ If this argument is %TRUE, the pixbuf's translation with respect
+ to its logical origin in item-relative coordinates will be in
+ pixels, that is, the visible offset will not change even if the
+ item's affine transformation changes. If it is %FALSE, the
+ pixbuf's translation will be taken to be in canvas units, and thus
+ will change along with the item's affine transformation. The
+ default is %FALSE.
+ </para>
+
+
+<!-- ##### SECTION ./tmpl/xlib-rgb.sgml:Title ##### -->
+XlibRGB
+
+
+<!-- ##### FUNCTION gdk_pixbuf_new_from_file ##### -->
+<para>
+
+</para>
+
+@filename:
+@error:
+@Returns: <!--
+Local variables:
+mode: sgml
+sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
+End:
+-->
+
diff --git a/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf.sgml b/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf.sgml
index 403941efa..897d59bf8 100644
--- a/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf.sgml
+++ b/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf.sgml
@@ -15,135 +15,3 @@ Information that describes an image.
<para>
</para>
-<!-- ##### ENUM GdkPixbufError ##### -->
-<para>
-
-</para>
-
-@GDK_PIXBUF_ERROR_CORRUPT_IMAGE:
-@GDK_PIXBUF_ERROR_INSUFFICIENT_MEMORY:
-@GDK_PIXBUF_ERROR_BAD_OPTION_VALUE:
-@GDK_PIXBUF_ERROR_UNKNOWN_TYPE:
-@GDK_PIXBUF_ERROR_UNSUPPORTED_OPERATION:
-@GDK_PIXBUF_ERROR_FAILED:
-
-<!-- ##### MACRO GDK_PIXBUF_ERROR ##### -->
-<para>
-
-</para>
-
-
-
-<!-- ##### ENUM GdkColorspace ##### -->
- <para>
- This enumeration defines the color spaces that are supported by
- the &gdk-pixbuf; library. Currently only RGB is supported.
- </para>
-
-@GDK_COLORSPACE_RGB: Indicates a red/green/blue additive color space.
-
-<!-- ##### ENUM GdkPixbufAlphaMode ##### -->
- <para>
- These values can be passed to
- gdk_pixbuf_render_to_drawable_alpha() to control how the alpha
- chanel of an image should be handled. This function can create a
- bilevel clipping mask (black and white) and use it while painting
- the image. In the future, when the X Window System gets an alpha
- channel extension, it will be possible to do full alpha
- compositing onto arbitrary drawables. For now both cases fall
- back to a bilevel clipping mask.
- </para>
-
-@GDK_PIXBUF_ALPHA_BILEVEL: A bilevel clipping mask (black and white)
-will be created and used to draw the image. Pixels below 0.5 opacity
-will be considered fully transparent, and all others will be
-considered fully opaque.
-@GDK_PIXBUF_ALPHA_FULL: For now falls back to #GDK_PIXBUF_ALPHA_BILEVEL.
-In the future it will do full alpha compositing.
-
-<!-- ##### STRUCT GdkPixbuf ##### -->
- <para>
- This is the main structure in the &gdk-pixbuf; library. It is
- used to represent images. It contains information about the
- image's pixel data, its color space, bits per sample, width and
- height, and the rowstride or number of bytes between rows.
- </para>
-
-
-<!-- ##### FUNCTION gdk_pixbuf_get_colorspace ##### -->
-<para>
-
-</para>
-
-@pixbuf:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_get_n_channels ##### -->
-<para>
-
-</para>
-
-@pixbuf:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_get_has_alpha ##### -->
-<para>
-
-</para>
-
-@pixbuf:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_get_bits_per_sample ##### -->
-<para>
-
-</para>
-
-@pixbuf:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_get_pixels ##### -->
-<para>
-
-</para>
-
-@pixbuf:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_get_width ##### -->
-<para>
-
-</para>
-
-@pixbuf:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_get_height ##### -->
-<para>
-
-</para>
-
-@pixbuf:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_get_rowstride ##### -->
-<para>
-
-</para>
-
-@pixbuf:
-@Returns: <!--
-Local variables:
-mode: sgml
-sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
-End:
--->
-
-
diff --git a/docs/reference/gdk-pixbuf/tmpl/initialization_versions.sgml b/docs/reference/gdk-pixbuf/tmpl/initialization_versions.sgml
index 41302c27c..26746d740 100644
--- a/docs/reference/gdk-pixbuf/tmpl/initialization_versions.sgml
+++ b/docs/reference/gdk-pixbuf/tmpl/initialization_versions.sgml
@@ -14,62 +14,3 @@ Initialization and Versions
</para>
-<!-- ##### FUNCTION gdk_pixbuf_init ##### -->
-<para>
-
-</para>
-
-
-
-<!-- ##### FUNCTION gdk_pixbuf_preinit ##### -->
-<para>
-
-</para>
-
-@app:
-@modinfo:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_postinit ##### -->
-<para>
-
-</para>
-
-@app:
-@modinfo:
-
-
-<!-- ##### VARIABLE gdk_pixbuf_version ##### -->
-<para>
-
-</para>
-
-
-<!-- ##### MACRO GDK_PIXBUF_VERSION ##### -->
-<para>
-
-</para>
-
-
-
-<!-- ##### MACRO GDK_PIXBUF_MAJOR ##### -->
-<para>
-
-</para>
-
-
-
-<!-- ##### MACRO GDK_PIXBUF_MINOR ##### -->
-<para>
-
-</para>
-
-
-
-<!-- ##### MACRO GDK_PIXBUF_MICRO ##### -->
-<para>
-
-</para>
-
-
-
diff --git a/docs/reference/gdk-pixbuf/tmpl/module_interface.sgml b/docs/reference/gdk-pixbuf/tmpl/module_interface.sgml
index 734ee8034..7e1402e2f 100644
--- a/docs/reference/gdk-pixbuf/tmpl/module_interface.sgml
+++ b/docs/reference/gdk-pixbuf/tmpl/module_interface.sgml
@@ -14,91 +14,3 @@ Module Interface
</para>
-<!-- ##### USER_FUNCTION ModulePreparedNotifyFunc ##### -->
-<para>
-
-</para>
-
-@pixbuf:
-@user_data:
-
-
-<!-- ##### USER_FUNCTION ModuleUpdatedNotifyFunc ##### -->
-<para>
-
-</para>
-
-@pixbuf:
-@x:
-@y:
-@width:
-@height:
-@user_data:
-
-
-<!-- ##### USER_FUNCTION ModuleFrameDoneNotifyFunc ##### -->
-<para>
-
-</para>
-
-@frame:
-@user_data:
-
-
-<!-- ##### USER_FUNCTION ModuleAnimationDoneNotifyFunc ##### -->
-<para>
-
-</para>
-
-@pixbuf:
-@user_data:
-
-
-<!-- ##### STRUCT GdkPixbufModule ##### -->
-<para>
-
-</para>
-
-@module_name:
-@format_check:
-@module:
-@load:
-@load_xpm_data:
-@begin_load:
-@stop_load:
-@load_increment:
-@load_animation:
-@save:
-
-<!-- ##### FUNCTION gdk_pixbuf_get_module ##### -->
-<para>
-
-</para>
-
-@buffer:
-@size:
-@filename:
-@error:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_get_named_module ##### -->
-<para>
-
-</para>
-
-@name:
-@error:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_load_module ##### -->
-<para>
-
-</para>
-
-@image_module:
-@error:
-@Returns:
-
-
diff --git a/docs/reference/gdk-pixbuf/tmpl/refcounting.sgml b/docs/reference/gdk-pixbuf/tmpl/refcounting.sgml
index f975e4f69..770b66ae1 100644
--- a/docs/reference/gdk-pixbuf/tmpl/refcounting.sgml
+++ b/docs/reference/gdk-pixbuf/tmpl/refcounting.sgml
@@ -54,34 +54,3 @@ Functions to perform reference counting and memory management on a
#GdkPixbuf, gdk_pixbuf_new_from_data().
</para>
-<!-- ##### USER_FUNCTION GdkPixbufDestroyNotify ##### -->
- <para>
- A function of this type is responsible for freeing the pixel array
- of a pixbuf. The gdk_pixbuf_new_from_data() function lets you
- pass in a pre-allocated pixel array so that a pixbuf can be
- created from it; in this case you will need to pass in a function
- of #GdkPixbufDestroyNotify so that the pixel data can be freed
- when the pixbuf is finalized.
- </para>
-
-@pixels: The pixel array of the pixbuf that is being finalized.
-@data: User closure data.
-
-
-<!-- ##### FUNCTION gdk_pixbuf_ref ##### -->
- <para>
-
- </para>
-
-@pixbuf:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_unref ##### -->
-<para>
-
-</para>
-
-@pixbuf:
-
-
diff --git a/docs/reference/gdk-pixbuf/tmpl/scaling.sgml b/docs/reference/gdk-pixbuf/tmpl/scaling.sgml
index a8d41a117..b4bf82445 100644
--- a/docs/reference/gdk-pixbuf/tmpl/scaling.sgml
+++ b/docs/reference/gdk-pixbuf/tmpl/scaling.sgml
@@ -68,127 +68,3 @@ expose_cb (GtkWidget *widget, GdkEventExpose *event, gpointer data)
GdkRGB
</para>
-<!-- ##### ENUM GdkInterpType ##### -->
- <para>
- This enumeration describes the different interpolation modes that
- can be used with the scaling functions.
-
- <note>
- <para>
- Cubic filtering is missing from the list; hyperbolic
- interpolation is just as fast and results in higher quality.
- </para>
- </note>
- </para>
-
-@GDK_INTERP_NEAREST: Nearest neighbor sampling; this is the fastest
-and lowest quality mode.
-@GDK_INTERP_TILES: This is an accurate simulation of the PostScript
-image operator without any interpolation enabled. Each pixel is
-rendered as a tiny parallelogram of solid color, the edges of which
-are implemented with antialiasing. It resembles nearest neighbor for
-enlargement, and bilinear for reduction.
-@GDK_INTERP_BILINEAR: Bilinear interpolation. For enlargement, it is
-equivalent to point-sampling the ideal bilinear-interpolated image.
-For reduction, it is equivalent to laying down small tiles and
-integrating over the coverage area.
-@GDK_INTERP_HYPER: This is the slowest and highest quality
-reconstruction function. It is derived from the hyperbolic filters in
-Wolberg's "Digital Image Warping", and is formally defined as the
-hyperbolic-filter sampling the ideal hyperbolic-filter interpolated
-image (the filter is designed to be idempotent for 1:1 pixel mapping).
-
-<!-- ##### FUNCTION gdk_pixbuf_scale ##### -->
-<para>
-
-</para>
-
-@src:
-@dest:
-@dest_x:
-@dest_y:
-@dest_width:
-@dest_height:
-@offset_x:
-@offset_y:
-@scale_x:
-@scale_y:
-@interp_type:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_composite ##### -->
-<para>
-
-</para>
-
-@src:
-@dest:
-@dest_x:
-@dest_y:
-@dest_width:
-@dest_height:
-@offset_x:
-@offset_y:
-@scale_x:
-@scale_y:
-@interp_type:
-@overall_alpha:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_composite_color ##### -->
-<para>
-
-</para>
-
-@src:
-@dest:
-@dest_x:
-@dest_y:
-@dest_width:
-@dest_height:
-@offset_x:
-@offset_y:
-@scale_x:
-@scale_y:
-@interp_type:
-@overall_alpha:
-@check_x:
-@check_y:
-@check_size:
-@color1:
-@color2:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_scale_simple ##### -->
-<para>
-
-</para>
-
-@src:
-@dest_width:
-@dest_height:
-@interp_type:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_composite_color_simple ##### -->
-<para>
-
-</para>
-
-@src:
-@dest_width:
-@dest_height:
-@interp_type:
-@overall_alpha:
-@check_size:
-@color1:
-@color2:
-@Returns: <!--
-Local variables:
-mode: sgml
-sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
-End:
--->
-
-
diff --git a/docs/reference/gdk-pixbuf/tmpl/util.sgml b/docs/reference/gdk-pixbuf/tmpl/util.sgml
index 35726a967..bb91711e7 100644
--- a/docs/reference/gdk-pixbuf/tmpl/util.sgml
+++ b/docs/reference/gdk-pixbuf/tmpl/util.sgml
@@ -17,47 +17,3 @@ Utility and miscellaneous convenience functions.
#GdkPixbuf
</para>
-<!-- ##### FUNCTION gdk_pixbuf_add_alpha ##### -->
-<para>
-
-</para>
-
-@pixbuf:
-@substitute_color:
-@r:
-@g:
-@b:
-@Returns:
-
-
-<!-- ##### FUNCTION gdk_pixbuf_copy_area ##### -->
-<para>
-
-</para>
-
-@src_pixbuf:
-@src_x:
-@src_y:
-@width:
-@height:
-@dest_pixbuf:
-@dest_x:
-@dest_y: <!--
-Local variables:
-mode: sgml
-sgml-parent-document: ("../gdk-pixbuf.sgml" "book" "refsect2" "")
-End:
--->
-
-
-<!-- ##### FUNCTION gdk_pixbuf_saturate_and_pixelate ##### -->
-<para>
-
-</para>
-
-@src:
-@dest:
-@saturation:
-@pixelate:
-
-
diff --git a/docs/reference/gdk/tmpl/gdk-unused.sgml b/docs/reference/gdk/tmpl/gdk-unused.sgml
index f45539021..830db8f65 100644
--- a/docs/reference/gdk/tmpl/gdk-unused.sgml
+++ b/docs/reference/gdk/tmpl/gdk-unused.sgml
@@ -1,8 +1,34 @@
-<!-- ##### SECTION ./tmpl/gdkregion.sgml:See_Also ##### -->
+<!-- ##### FUNCTION gdk_input_set_mode ##### -->
<para>
+Enables or disables a device, and determines how the
+device maps onto the screen.
+</para>
+@deviceid: the device to configure.
+@mode: the new mode.
+@Returns: %TRUE if the device supports the given mode, otherwise
+ %FALSE and the device's mode is unchanged.
+
+<!-- ##### FUNCTION gdk_input_set_key ##### -->
+<para>
+Sets the key event generated when a macro button is pressed.
</para>
+@deviceid: the device to configure.
+@index: the index of the macro button.
+@keyval: the key value for the #GdkKeypressEvent to generate.
+ (a value of 0 means no event will be generated.)
+@modifiers: the modifier field for the generated
+ #GdkKeyPressEvent.
+
+<!-- ##### FUNCTION gdk_regions_intersect ##### -->
+<para>
+Returns the intersection of two regions.
+</para>
+
+@source1: a #GdkRegion.
+@source2: a #GdkRegion.
+@Returns: the intersection of @source1 and @source2.
<!-- ##### FUNCTION gdk_regions_xor ##### -->
<para>
@@ -16,21 +42,32 @@ but which are not in both.
@Returns: the difference between the union and the intersection of @source1
and @source2.
-<!-- ##### FUNCTION gdk_input_motion_events ##### -->
+<!-- ##### FUNCTION gdk_regions_subtract ##### -->
<para>
-Retrieves the motion history for a given device/window pair.
+Subtracts one region from another.
+The result is a region containing all the pixels which are in @source1, but
+which are not in @source2.
</para>
-@window: a #GdkWindow.
-@deviceid: the device for which to retrieve motion history.
-@start: the start time.
-@stop: the stop time.
-@nevents_return: location to store the number of events returned.
-@Returns: a newly allocated array containing all the events
- from @start to @stop. This array should be freed
- with g_free() when you are finished using it.
+@source1: a #GdkRegion.
+@source2: a #GdkRegion to subtract from @source1.
+@Returns: @source1 - @source2.
-<!-- ##### SECTION ./tmpl/gdkregion.sgml:Long_Description ##### -->
+<!-- ##### FUNCTION gdk_input_list_devices ##### -->
+<para>
+Lists all available input devices, along with their
+configuration information.
+</para>
+
+@Returns: A #GList of #GdkDeviceInfo structures. This list
+ is internal data of GTK+ and should not be modified
+ or freed.
+
+<!-- ##### SECTION ./tmpl/gdkregion.sgml:Short_Description ##### -->
+
+
+
+<!-- ##### SECTION ./tmpl/input_methods.sgml.sgml:See_Also ##### -->
<para>
</para>
@@ -40,6 +77,29 @@ Retrieves the motion history for a given device/window pair.
+<!-- ##### MACRO GDK_CORE_POINTER ##### -->
+<para>
+This macro contains an integer value representing
+the device ID for the core pointer device.
+</para>
+
+
+<!-- ##### VARIABLE gdk_threads_mutex ##### -->
+<para>
+
+</para>
+
+
+<!-- ##### FUNCTION gdk_input_set_axes ##### -->
+<para>
+Sets the mapping of the axes (valuators) of a device
+onto the predefined valuator types that GTK+ understands.
+</para>
+
+@deviceid: the device to configure.
+@axes: an array of GdkAxisUse. This length of this array
+ must match the number of axes for the device.
+
<!-- ##### STRUCT GdkDeviceInfo ##### -->
<para>
The #GdkDeviceInfo structure contains information about a
@@ -64,70 +124,69 @@ device. It has the following fields:
which describe what key press events are generated
for each macro button.
-<!-- ##### SECTION ./tmpl/input_methods.sgml.sgml:Title ##### -->
-Pango Interaction
+<!-- ##### SECTION ./tmpl/gdkregion.sgml:Title ##### -->
+Points, Rectangles and Regions
-<!-- ##### FUNCTION gdk_regions_union ##### -->
+<!-- ##### SECTION ./tmpl/input_methods.sgml.sgml:Long_Description ##### -->
<para>
-Returns the union of two regions.
-This is all pixels in either of @source1 or @source2.
+
</para>
-@source1: a #GdkRegion.
-@source2: a #GdkRegion.
-@Returns: the union of @source1 and @source2.
-<!-- ##### SECTION ./tmpl/gdkregion.sgml:Short_Description ##### -->
+<!-- ##### ENUM GdkPixbufAlphaMode ##### -->
+<para>
+</para>
+@GDK_PIXBUF_ALPHA_BILEVEL:
+@GDK_PIXBUF_ALPHA_FULL:
-<!-- ##### FUNCTION gdk_input_set_key ##### -->
+<!-- ##### FUNCTION gdk_input_motion_events ##### -->
<para>
-Sets the key event generated when a macro button is pressed.
+Retrieves the motion history for a given device/window pair.
</para>
-@deviceid: the device to configure.
-@index: the index of the macro button.
-@keyval: the key value for the #GdkKeypressEvent to generate.
- (a value of 0 means no event will be generated.)
-@modifiers: the modifier field for the generated
- #GdkKeyPressEvent.
+@window: a #GdkWindow.
+@deviceid: the device for which to retrieve motion history.
+@start: the start time.
+@stop: the stop time.
+@nevents_return: location to store the number of events returned.
+@Returns: a newly allocated array containing all the events
+ from @start to @stop. This array should be freed
+ with g_free() when you are finished using it.
-<!-- ##### FUNCTION gdk_input_list_devices ##### -->
+<!-- ##### VARIABLE gdk_core_pointer ##### -->
<para>
-Lists all available input devices, along with their
-configuration information.
+
</para>
-@Returns: A #GList of #GdkDeviceInfo structures. This list
- is internal data of GTK+ and should not be modified
- or freed.
-<!-- ##### SECTION ./tmpl/input_methods.sgml.sgml:See_Also ##### -->
+<!-- ##### SECTION ./tmpl/gdkregion.sgml:See_Also ##### -->
<para>
</para>
-<!-- ##### ENUM GdkPixbufAlphaMode ##### -->
+<!-- ##### SECTION ./tmpl/input_methods.sgml.sgml:Title ##### -->
+Pango Interaction
+
+
+<!-- ##### SECTION ./tmpl/gdkregion.sgml:Long_Description ##### -->
<para>
</para>
-@GDK_PIXBUF_ALPHA_BILEVEL:
-@GDK_PIXBUF_ALPHA_FULL:
-<!-- ##### FUNCTION gdk_regions_subtract ##### -->
+<!-- ##### FUNCTION gdk_regions_union ##### -->
<para>
-Subtracts one region from another.
-The result is a region containing all the pixels which are in @source1, but
-which are not in @source2.
+Returns the union of two regions.
+This is all pixels in either of @source1 or @source2.
</para>
@source1: a #GdkRegion.
-@source2: a #GdkRegion to subtract from @source1.
-@Returns: @source1 - @source2.
+@source2: a #GdkRegion.
+@Returns: the union of @source1 and @source2.
<!-- ##### FUNCTION gdk_input_window_get_pointer ##### -->
<para>
@@ -146,23 +205,6 @@ they will be ignored.
@ytilt: location to store current tilt in the y direction.
@mask: location to store the current modifier state.
-<!-- ##### MACRO GDK_CORE_POINTER ##### -->
-<para>
-This macro contains an integer value representing
-the device ID for the core pointer device.
-</para>
-
-
-<!-- ##### FUNCTION gdk_input_set_axes ##### -->
-<para>
-Sets the mapping of the axes (valuators) of a device
-onto the predefined valuator types that GTK+ understands.
-</para>
-
-@deviceid: the device to configure.
-@axes: an array of GdkAxisUse. This length of this array
- must match the number of axes for the device.
-
<!-- ##### FUNCTION gdk_input_set_source ##### -->
<para>
Sets the source type for a device.
@@ -171,33 +213,3 @@ Sets the source type for a device.
@deviceid: the device to configure
@source: the new source type.
-<!-- ##### SECTION ./tmpl/gdkregion.sgml:Title ##### -->
-Points, Rectangles and Regions
-
-
-<!-- ##### FUNCTION gdk_regions_intersect ##### -->
-<para>
-Returns the intersection of two regions.
-</para>
-
-@source1: a #GdkRegion.
-@source2: a #GdkRegion.
-@Returns: the intersection of @source1 and @source2.
-
-<!-- ##### FUNCTION gdk_input_set_mode ##### -->
-<para>
-Enables or disables a device, and determines how the
-device maps onto the screen.
-</para>
-
-@deviceid: the device to configure.
-@mode: the new mode.
-@Returns: %TRUE if the device supports the given mode, otherwise
- %FALSE and the device's mode is unchanged.
-
-<!-- ##### SECTION ./tmpl/input_methods.sgml.sgml:Long_Description ##### -->
-<para>
-
-</para>
-
-
diff --git a/docs/reference/gdk/tmpl/input_devices.sgml b/docs/reference/gdk/tmpl/input_devices.sgml
index 572bd6974..1f9b99c12 100644
--- a/docs/reference/gdk/tmpl/input_devices.sgml
+++ b/docs/reference/gdk/tmpl/input_devices.sgml
@@ -175,12 +175,6 @@ types that GTK+ understands.
@Returns:
-<!-- ##### VARIABLE gdk_core_pointer ##### -->
-<para>
-
-</para>
-
-
<!-- ##### FUNCTION gdk_device_set_source ##### -->
<para>
diff --git a/docs/reference/gdk/tmpl/threads.sgml b/docs/reference/gdk/tmpl/threads.sgml
index 5e7e049ab..4bc696e76 100644
--- a/docs/reference/gdk/tmpl/threads.sgml
+++ b/docs/reference/gdk/tmpl/threads.sgml
@@ -42,9 +42,3 @@ Threads
-<!-- ##### VARIABLE gdk_threads_mutex ##### -->
-<para>
-
-</para>
-
-
diff --git a/gdk-pixbuf/gdk-pixbuf-animation.c b/gdk-pixbuf/gdk-pixbuf-animation.c
index 16dc26d6c..9d221d5c3 100644
--- a/gdk-pixbuf/gdk-pixbuf-animation.c
+++ b/gdk-pixbuf/gdk-pixbuf-animation.c
@@ -53,7 +53,7 @@ gdk_pixbuf_animation_get_type (void)
object_type = g_type_register_static (G_TYPE_OBJECT,
"GdkPixbufAnimation",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gdk-pixbuf/gdk-pixbuf-loader.c b/gdk-pixbuf/gdk-pixbuf-loader.c
index 42aec5d4c..22d7ba107 100644
--- a/gdk-pixbuf/gdk-pixbuf-loader.c
+++ b/gdk-pixbuf/gdk-pixbuf-loader.c
@@ -66,26 +66,6 @@ typedef struct
} GdkPixbufLoaderPrivate;
-/* our marshaller */
-typedef void (*GtkSignal_NONE__INT_INT_INT_INT) (GtkObject *object,
- gint arg1, gint arg2, gint arg3, gint arg4,
- gpointer user_data);
-static void
-gtk_marshal_NONE__INT_INT_INT_INT (GtkObject *object, GtkSignalFunc func, gpointer func_data,
- GtkArg * args)
-{
- GtkSignal_NONE__INT_INT_INT_INT rfunc;
-
- rfunc = (GtkSignal_NONE__INT_INT_INT_INT) func;
- (*rfunc) (object,
- GTK_VALUE_INT (args[0]),
- GTK_VALUE_INT (args[1]),
- GTK_VALUE_INT (args[2]),
- GTK_VALUE_INT (args[3]),
- func_data);
-}
-
-
/**
* gdk_pixbuf_loader_get_type:
* @void:
@@ -135,7 +115,7 @@ gdk_pixbuf_loader_class_init (GdkPixbufLoaderClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GdkPixbufLoaderClass, area_prepared),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
pixbuf_loader_signals[AREA_UPDATED] =
@@ -143,7 +123,7 @@ gdk_pixbuf_loader_class_init (GdkPixbufLoaderClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GdkPixbufLoaderClass, area_updated),
- gtk_marshal_NONE__INT_INT_INT_INT,
+ gtk_marshal_VOID__INT_INT_INT_INT,
GTK_TYPE_NONE, 4,
GTK_TYPE_INT,
GTK_TYPE_INT,
@@ -155,7 +135,7 @@ gdk_pixbuf_loader_class_init (GdkPixbufLoaderClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GdkPixbufLoaderClass, frame_done),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_POINTER);
@@ -164,7 +144,7 @@ gdk_pixbuf_loader_class_init (GdkPixbufLoaderClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GdkPixbufLoaderClass, animation_done),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
pixbuf_loader_signals[CLOSED] =
@@ -172,7 +152,7 @@ gdk_pixbuf_loader_class_init (GdkPixbufLoaderClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GdkPixbufLoaderClass, closed),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, pixbuf_loader_signals, LAST_SIGNAL);
diff --git a/gdk-pixbuf/gdk-pixbuf.c b/gdk-pixbuf/gdk-pixbuf.c
index a515ea55b..84e086e72 100644
--- a/gdk-pixbuf/gdk-pixbuf.c
+++ b/gdk-pixbuf/gdk-pixbuf.c
@@ -56,7 +56,7 @@ gdk_pixbuf_get_type (void)
object_type = g_type_register_static (G_TYPE_OBJECT,
"GdkPixbuf",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gdk/gdkdraw.c b/gdk/gdkdraw.c
index d2c7e4016..facc185e9 100644
--- a/gdk/gdkdraw.c
+++ b/gdk/gdkdraw.c
@@ -60,7 +60,7 @@ gdk_drawable_get_type (void)
object_type = g_type_register_static (G_TYPE_OBJECT,
"GdkDrawable",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gdk/gdkgc.c b/gdk/gdkgc.c
index 8bc2a97ab..7a482b245 100644
--- a/gdk/gdkgc.c
+++ b/gdk/gdkgc.c
@@ -57,7 +57,7 @@ gdk_gc_get_type (void)
object_type = g_type_register_static (G_TYPE_OBJECT,
"GdkGC",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gdk/gdkpixmap.c b/gdk/gdkpixmap.c
index 8b44d8728..27fc5f631 100644
--- a/gdk/gdkpixmap.c
+++ b/gdk/gdkpixmap.c
@@ -148,7 +148,7 @@ gdk_pixmap_get_type (void)
object_type = g_type_register_static (GDK_TYPE_DRAWABLE,
"GdkPixmap",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gdk/gdkwindow.c b/gdk/gdkwindow.c
index c4c241951..291830e21 100644
--- a/gdk/gdkwindow.c
+++ b/gdk/gdkwindow.c
@@ -177,7 +177,7 @@ gdk_window_object_get_type (void)
object_type = g_type_register_static (GDK_TYPE_DRAWABLE,
"GdkWindow",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gdk/x11/gdkcolor-x11.c b/gdk/x11/gdkcolor-x11.c
index 27cac85c8..cd78240f9 100644
--- a/gdk/x11/gdkcolor-x11.c
+++ b/gdk/x11/gdkcolor-x11.c
@@ -70,7 +70,7 @@ gdk_colormap_get_type (void)
object_type = g_type_register_static (G_TYPE_OBJECT,
"GdkColormap",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gdk/x11/gdkdnd-x11.c b/gdk/x11/gdkdnd-x11.c
index 7c4fb682e..28478eeb9 100644
--- a/gdk/x11/gdkdnd-x11.c
+++ b/gdk/x11/gdkdnd-x11.c
@@ -152,7 +152,7 @@ gdk_drag_context_get_type (void)
object_type = g_type_register_static (G_TYPE_OBJECT,
"GdkDragContext",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gdk/x11/gdkdrawable-x11.c b/gdk/x11/gdkdrawable-x11.c
index 058c44726..9eaf0ad96 100644
--- a/gdk/x11/gdkdrawable-x11.c
+++ b/gdk/x11/gdkdrawable-x11.c
@@ -149,7 +149,7 @@ gdk_drawable_impl_x11_get_type (void)
object_type = g_type_register_static (GDK_TYPE_DRAWABLE,
"GdkDrawableImplX11",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gdk/x11/gdkgc-x11.c b/gdk/x11/gdkgc-x11.c
index 130500434..a5b0088b0 100644
--- a/gdk/x11/gdkgc-x11.c
+++ b/gdk/x11/gdkgc-x11.c
@@ -77,7 +77,7 @@ gdk_gc_x11_get_type (void)
object_type = g_type_register_static (GDK_TYPE_GC,
"GdkGCX11",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gdk/x11/gdkimage-x11.c b/gdk/x11/gdkimage-x11.c
index 519ff2789..1eeee2297 100644
--- a/gdk/x11/gdkimage-x11.c
+++ b/gdk/x11/gdkimage-x11.c
@@ -92,7 +92,7 @@ gdk_image_get_type (void)
object_type = g_type_register_static (G_TYPE_OBJECT,
"GdkImage",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gdk/x11/gdkpixmap-x11.c b/gdk/x11/gdkpixmap-x11.c
index 66d34562a..03ef5888c 100644
--- a/gdk/x11/gdkpixmap-x11.c
+++ b/gdk/x11/gdkpixmap-x11.c
@@ -82,7 +82,7 @@ gdk_pixmap_impl_x11_get_type (void)
object_type = g_type_register_static (GDK_TYPE_DRAWABLE_IMPL_X11,
"GdkPixmapImplX11",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gdk/x11/gdkwindow-x11.c b/gdk/x11/gdkwindow-x11.c
index 1accdd1c1..3aee23b03 100644
--- a/gdk/x11/gdkwindow-x11.c
+++ b/gdk/x11/gdkwindow-x11.c
@@ -115,7 +115,7 @@ gdk_window_impl_x11_get_type (void)
object_type = g_type_register_static (GDK_TYPE_DRAWABLE_IMPL_X11,
"GdkWindowImplX11",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gtk/Makefile.am b/gtk/Makefile.am
index 6dbee7dba..bb5c73507 100644
--- a/gtk/Makefile.am
+++ b/gtk/Makefile.am
@@ -285,7 +285,6 @@ gtk_c_sources = @STRIP_BEGIN@ \
gtklistitem.c \
gtkliststore.c \
gtkmain.c \
- gtkmarshal.c \
gtkmenu.c \
gtkmenubar.c \
gtkmenufactory.c \
@@ -400,7 +399,7 @@ gtk_extra_sources = @STRIP_BEGIN@ \
makeenums.h \
gtkargcollector.c \
gtk-boxed.defs \
- genmarshal.pl \
+ genmarshal.c \
gtkmarshal.list \
@STRIP_END@
# Extra headers that are used for enum type array/id generation
@@ -486,11 +485,10 @@ $(srcdir)/stamp-gtk.defs: @REBUILD@ makeenums.pl gtk.defs gtk-boxed.defs $(gtk_p
&& rm -f xgen-gdef \
&& echo timestamp > $(@F)
$(srcdir)/gtkmarshal.c: stamp-gtkmarshal.h
-$(srcdir)/gtkmarshal.c $(srcdir)/stamp-gtkmarshal.h: @REBUILD@ genmarshal.pl gtkmarshal.list gtkmarshal.h
+$(srcdir)/gtkmarshal.c $(srcdir)/stamp-gtkmarshal.h: @REBUILD@ gtkmarshal.list gtkmarshal.h
cd $(srcdir) \
- && $(PERL) genmarshal.pl gtkmarshal.list xgen-gmh xgen-gmc \
- && (test -z "$(INDENT)" || $(INDENT) xgen-gmh) \
- && (test -z "$(INDENT)" || $(INDENT) xgen-gmc) \
+ && glib-genmarshal --prefix=gtk_marshal gtkmarshal.list --header --skip-source >> xgen-gmh \
+ && glib-genmarshal --prefix=gtk_marshal gtkmarshal.list --body >> xgen-gmc \
&& cp xgen-gmc gtkmarshal.c \
&& (cmp -s xgen-gmh gtkmarshal.h || cp xgen-gmh gtkmarshal.h) \
&& rm -f xgen-gmh xgen-gmc xgen-gmh~ xgen-gmc~ \
diff --git a/gtk/gdk-pixbuf-loader.c b/gtk/gdk-pixbuf-loader.c
index 42aec5d4c..22d7ba107 100644
--- a/gtk/gdk-pixbuf-loader.c
+++ b/gtk/gdk-pixbuf-loader.c
@@ -66,26 +66,6 @@ typedef struct
} GdkPixbufLoaderPrivate;
-/* our marshaller */
-typedef void (*GtkSignal_NONE__INT_INT_INT_INT) (GtkObject *object,
- gint arg1, gint arg2, gint arg3, gint arg4,
- gpointer user_data);
-static void
-gtk_marshal_NONE__INT_INT_INT_INT (GtkObject *object, GtkSignalFunc func, gpointer func_data,
- GtkArg * args)
-{
- GtkSignal_NONE__INT_INT_INT_INT rfunc;
-
- rfunc = (GtkSignal_NONE__INT_INT_INT_INT) func;
- (*rfunc) (object,
- GTK_VALUE_INT (args[0]),
- GTK_VALUE_INT (args[1]),
- GTK_VALUE_INT (args[2]),
- GTK_VALUE_INT (args[3]),
- func_data);
-}
-
-
/**
* gdk_pixbuf_loader_get_type:
* @void:
@@ -135,7 +115,7 @@ gdk_pixbuf_loader_class_init (GdkPixbufLoaderClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GdkPixbufLoaderClass, area_prepared),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
pixbuf_loader_signals[AREA_UPDATED] =
@@ -143,7 +123,7 @@ gdk_pixbuf_loader_class_init (GdkPixbufLoaderClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GdkPixbufLoaderClass, area_updated),
- gtk_marshal_NONE__INT_INT_INT_INT,
+ gtk_marshal_VOID__INT_INT_INT_INT,
GTK_TYPE_NONE, 4,
GTK_TYPE_INT,
GTK_TYPE_INT,
@@ -155,7 +135,7 @@ gdk_pixbuf_loader_class_init (GdkPixbufLoaderClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GdkPixbufLoaderClass, frame_done),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_POINTER);
@@ -164,7 +144,7 @@ gdk_pixbuf_loader_class_init (GdkPixbufLoaderClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GdkPixbufLoaderClass, animation_done),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
pixbuf_loader_signals[CLOSED] =
@@ -172,7 +152,7 @@ gdk_pixbuf_loader_class_init (GdkPixbufLoaderClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GdkPixbufLoaderClass, closed),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, pixbuf_loader_signals, LAST_SIGNAL);
diff --git a/gtk/gtkaccelgroup.c b/gtk/gtkaccelgroup.c
index 6cbc8396f..c5343508b 100644
--- a/gtk/gtkaccelgroup.c
+++ b/gtk/gtkaccelgroup.c
@@ -342,7 +342,7 @@ gtk_accel_group_add (GtkAccelGroup *accel_group,
guint add_accelerator_signal_id = 0;
guint remove_accelerator_signal_id = 0;
gchar *signal;
- GtkSignalQuery *query;
+ GSignalQuery query;
GSList *slist;
GSList *groups;
GSList *attach_objects;
@@ -377,20 +377,16 @@ gtk_accel_group_add (GtkAccelGroup *accel_group,
gtk_type_name (GTK_OBJECT_TYPE (object)));
return;
}
- query = gtk_signal_query (accel_signal_id);
- if (!query ||
- query->nparams > 0)
+ g_signal_query (accel_signal_id, &query);
+ if (!query.signal_id || query.n_params > 0)
{
g_warning ("gtk_accel_group_add(): signal \"%s\" in the `%s' class ancestry"
"cannot be used as accelerator signal",
accel_signal,
gtk_type_name (GTK_OBJECT_TYPE (object)));
- if (query)
- g_free (query);
return;
}
- g_free (query);
/* prematurely abort if the group/entry is already locked
*/
@@ -662,7 +658,7 @@ gtk_accel_group_create_add (GtkType class_type,
signal_flags,
class_type,
handler_offset,
- gtk_marshal_NONE__UINT_POINTER_UINT_UINT_ENUM,
+ gtk_marshal_VOID__UINT_BOXED_UINT_FLAGS_FLAGS,
GTK_TYPE_NONE, 5,
GTK_TYPE_UINT,
GTK_TYPE_ACCEL_GROUP,
@@ -682,7 +678,7 @@ gtk_accel_group_create_remove (GtkType class_type,
signal_flags,
class_type,
handler_offset,
- gtk_marshal_NONE__POINTER_UINT_UINT,
+ gtk_marshal_VOID__BOXED_UINT_FLAGS,
GTK_TYPE_NONE, 3,
GTK_TYPE_ACCEL_GROUP,
GTK_TYPE_UINT,
diff --git a/gtk/gtkadjustment.c b/gtk/gtkadjustment.c
index f4677cffe..084a5ef50 100644
--- a/gtk/gtkadjustment.c
+++ b/gtk/gtkadjustment.c
@@ -79,14 +79,14 @@ gtk_adjustment_class_init (GtkAdjustmentClass *class)
GTK_RUN_FIRST | GTK_RUN_NO_RECURSE,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkAdjustmentClass, changed),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
adjustment_signals[VALUE_CHANGED] =
gtk_signal_new ("value_changed",
GTK_RUN_FIRST | GTK_RUN_NO_RECURSE,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkAdjustmentClass, value_changed),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, adjustment_signals, LAST_SIGNAL);
diff --git a/gtk/gtkbindings.c b/gtk/gtkbindings.c
index 37e82612a..4004622f7 100644
--- a/gtk/gtkbindings.c
+++ b/gtk/gtkbindings.c
@@ -252,7 +252,7 @@ binding_ht_lookup_entry (GtkBindingSet *set,
static gboolean
binding_compose_params (GtkBindingArg *args,
- GtkSignalQuery *query,
+ GSignalQuery *query,
GtkArg **params_p)
{
GtkArg *params;
@@ -260,12 +260,12 @@ binding_compose_params (GtkBindingArg *args,
guint i;
gboolean valid;
- params = g_new0 (GtkArg, query->nparams);
+ params = g_new0 (GtkArg, query->n_params);
*params_p = params;
- types = query->params;
+ types = query->param_types;
valid = TRUE;
- for (i = 0; i < query->nparams && valid; i++)
+ for (i = 0; i < query->n_params && valid; i++)
{
GtkType param_ftype;
@@ -357,7 +357,7 @@ gtk_binding_entry_activate (GtkBindingEntry *entry,
for (sig = entry->signals; sig; sig = sig->next)
{
- GtkSignalQuery *query;
+ GSignalQuery query;
guint signal_id;
GtkArg *params = NULL;
gchar *accelerator = NULL;
@@ -376,10 +376,10 @@ gtk_binding_entry_activate (GtkBindingEntry *entry,
continue;
}
- query = gtk_signal_query (signal_id);
- if (query->nparams != sig->n_args ||
- query->return_val != GTK_TYPE_NONE ||
- !binding_compose_params (sig->args, query, &params))
+ g_signal_query (signal_id, &query);
+ if (query.n_params != sig->n_args ||
+ query.return_type != G_TYPE_NONE ||
+ !binding_compose_params (sig->args, &query, &params))
{
accelerator = gtk_accelerator_name (entry->keyval, entry->modifiers);
g_warning ("gtk_binding_entry_activate(): binding \"%s::%s\": "
@@ -389,7 +389,7 @@ gtk_binding_entry_activate (GtkBindingEntry *entry,
sig->signal_name,
gtk_type_name (GTK_OBJECT_TYPE (object)));
}
- else if (!(query->signal_flags & GTK_RUN_ACTION))
+ else if (!(query.signal_flags & GTK_RUN_ACTION))
{
accelerator = gtk_accelerator_name (entry->keyval, entry->modifiers);
g_warning ("gtk_binding_entry_activate(): binding \"%s::%s\": "
@@ -400,7 +400,6 @@ gtk_binding_entry_activate (GtkBindingEntry *entry,
gtk_type_name (GTK_OBJECT_TYPE (object)));
}
g_free (accelerator);
- g_free (query);
if (accelerator)
continue;
diff --git a/gtk/gtkbutton.c b/gtk/gtkbutton.c
index 394688496..2898cc0db 100644
--- a/gtk/gtkbutton.c
+++ b/gtk/gtkbutton.c
@@ -125,7 +125,7 @@ gtk_button_get_type (void)
(GInstanceInitFunc) gtk_button_init,
};
- button_type = g_type_register_static (GTK_TYPE_BIN, "GtkButton", &button_info);
+ button_type = g_type_register_static (GTK_TYPE_BIN, "GtkButton", &button_info, 0);
}
return button_type;
@@ -152,35 +152,35 @@ gtk_button_class_init (GtkButtonClass *klass)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkButtonClass, pressed),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
button_signals[RELEASED] =
gtk_signal_new ("released",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkButtonClass, released),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
button_signals[CLICKED] =
gtk_signal_new ("clicked",
GTK_RUN_FIRST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkButtonClass, clicked),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
button_signals[ENTER] =
gtk_signal_new ("enter",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkButtonClass, enter),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
button_signals[LEAVE] =
gtk_signal_new ("leave",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkButtonClass, leave),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, button_signals, LAST_SIGNAL);
diff --git a/gtk/gtkcalendar.c b/gtk/gtkcalendar.c
index 90b2c8d0d..5b0a61627 100644
--- a/gtk/gtkcalendar.c
+++ b/gtk/gtkcalendar.c
@@ -337,7 +337,7 @@ gtk_calendar_get_type (void)
(GInstanceInitFunc) gtk_calendar_init,
};
- calendar_type = g_type_register_static (GTK_TYPE_WIDGET, "GtkCalendar", &calendar_info);
+ calendar_type = g_type_register_static (GTK_TYPE_WIDGET, "GtkCalendar", &calendar_info, 0);
}
return calendar_type;
diff --git a/gtk/gtkcellrenderer.c b/gtk/gtkcellrenderer.c
index 5a12dc21e..75d34ee04 100644
--- a/gtk/gtkcellrenderer.c
+++ b/gtk/gtkcellrenderer.c
@@ -66,7 +66,7 @@ gtk_cell_renderer_get_type (void)
(GInstanceInitFunc) gtk_cell_renderer_init,
};
- cell_type = g_type_register_static (GTK_TYPE_OBJECT, "GtkCellRenderer", &cell_info);
+ cell_type = g_type_register_static (GTK_TYPE_OBJECT, "GtkCellRenderer", &cell_info, 0);
}
return cell_type;
diff --git a/gtk/gtkcellrendererpixbuf.c b/gtk/gtkcellrendererpixbuf.c
index c37cb5afb..50d6a9fe7 100644
--- a/gtk/gtkcellrendererpixbuf.c
+++ b/gtk/gtkcellrendererpixbuf.c
@@ -76,7 +76,7 @@ gtk_cell_renderer_pixbuf_get_type (void)
(GInstanceInitFunc) gtk_cell_renderer_pixbuf_init,
};
- cell_pixbuf_type = g_type_register_static (GTK_TYPE_CELL_RENDERER, "GtkCellRendererPixbuf", &cell_pixbuf_info);
+ cell_pixbuf_type = g_type_register_static (GTK_TYPE_CELL_RENDERER, "GtkCellRendererPixbuf", &cell_pixbuf_info, 0);
}
return cell_pixbuf_type;
diff --git a/gtk/gtkcellrenderertext.c b/gtk/gtkcellrenderertext.c
index 9925f03ee..159aa5ceb 100644
--- a/gtk/gtkcellrenderertext.c
+++ b/gtk/gtkcellrenderertext.c
@@ -85,7 +85,7 @@ gtk_cell_renderer_text_get_type (void)
(GInstanceInitFunc) gtk_cell_renderer_text_init,
};
- cell_text_type = g_type_register_static (GTK_TYPE_CELL_RENDERER, "GtkCellRendererText", &cell_text_info);
+ cell_text_type = g_type_register_static (GTK_TYPE_CELL_RENDERER, "GtkCellRendererText", &cell_text_info, 0);
}
return cell_text_type;
diff --git a/gtk/gtkcellrenderertextpixbuf.c b/gtk/gtkcellrenderertextpixbuf.c
index 3929a1333..d2fe42dac 100644
--- a/gtk/gtkcellrenderertextpixbuf.c
+++ b/gtk/gtkcellrenderertextpixbuf.c
@@ -83,7 +83,7 @@ gtk_cell_renderer_text_pixbuf_get_type (void)
(GInstanceInitFunc) gtk_cell_renderer_text_pixbuf_init,
};
- cell_text_pixbuf_type = g_type_register_static (GTK_TYPE_CELL_RENDERER_TEXT, "GtkCellRendererTextPixbuf", &cell_text_pixbuf_info);
+ cell_text_pixbuf_type = g_type_register_static (GTK_TYPE_CELL_RENDERER_TEXT, "GtkCellRendererTextPixbuf", &cell_text_pixbuf_info, 0);
}
return cell_text_pixbuf_type;
diff --git a/gtk/gtkcellrenderertoggle.c b/gtk/gtkcellrenderertoggle.c
index 6830604b4..238049d05 100644
--- a/gtk/gtkcellrenderertoggle.c
+++ b/gtk/gtkcellrenderertoggle.c
@@ -95,7 +95,7 @@ gtk_cell_renderer_toggle_get_type (void)
(GInstanceInitFunc) gtk_cell_renderer_toggle_init,
};
- cell_toggle_type = g_type_register_static (GTK_TYPE_CELL_RENDERER, "GtkCellRendererToggle", &cell_toggle_info);
+ cell_toggle_type = g_type_register_static (GTK_TYPE_CELL_RENDERER, "GtkCellRendererToggle", &cell_toggle_info, 0);
}
return cell_toggle_type;
@@ -147,7 +147,7 @@ gtk_cell_renderer_toggle_class_init (GtkCellRendererToggleClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCellRendererToggleClass, toggled),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_POINTER);
diff --git a/gtk/gtkcheckmenuitem.c b/gtk/gtkcheckmenuitem.c
index 3740da660..3d3b707e2 100644
--- a/gtk/gtkcheckmenuitem.c
+++ b/gtk/gtkcheckmenuitem.c
@@ -106,7 +106,7 @@ gtk_check_menu_item_class_init (GtkCheckMenuItemClass *klass)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCheckMenuItemClass, toggled),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, check_menu_item_signals, LAST_SIGNAL);
}
diff --git a/gtk/gtkclist.c b/gtk/gtkclist.c
index 9fa74569f..4519ac87b 100644
--- a/gtk/gtkclist.c
+++ b/gtk/gtkclist.c
@@ -544,7 +544,7 @@ gtk_clist_class_init (GtkCListClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, set_scroll_adjustments),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE, 2, GTK_TYPE_ADJUSTMENT, GTK_TYPE_ADJUSTMENT);
clist_signals[SELECT_ROW] =
@@ -552,7 +552,7 @@ gtk_clist_class_init (GtkCListClass *klass)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, select_row),
- gtk_marshal_NONE__INT_INT_POINTER,
+ gtk_marshal_VOID__INT_INT_POINTER,
GTK_TYPE_NONE, 3,
GTK_TYPE_INT,
GTK_TYPE_INT,
@@ -562,7 +562,7 @@ gtk_clist_class_init (GtkCListClass *klass)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, unselect_row),
- gtk_marshal_NONE__INT_INT_POINTER,
+ gtk_marshal_VOID__INT_INT_POINTER,
GTK_TYPE_NONE, 3, GTK_TYPE_INT,
GTK_TYPE_INT, GTK_TYPE_GDK_EVENT);
clist_signals[ROW_MOVE] =
@@ -570,21 +570,21 @@ gtk_clist_class_init (GtkCListClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, row_move),
- gtk_marshal_NONE__INT_INT,
+ gtk_marshal_VOID__INT_INT,
GTK_TYPE_NONE, 2, GTK_TYPE_INT, GTK_TYPE_INT);
clist_signals[CLICK_COLUMN] =
gtk_signal_new ("click_column",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, click_column),
- gtk_marshal_NONE__INT,
+ gtk_marshal_VOID__INT,
GTK_TYPE_NONE, 1, GTK_TYPE_INT);
clist_signals[RESIZE_COLUMN] =
gtk_signal_new ("resize_column",
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, resize_column),
- gtk_marshal_NONE__INT_INT,
+ gtk_marshal_VOID__INT_INT,
GTK_TYPE_NONE, 2, GTK_TYPE_INT, GTK_TYPE_INT);
clist_signals[TOGGLE_FOCUS_ROW] =
@@ -592,56 +592,56 @@ gtk_clist_class_init (GtkCListClass *klass)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, toggle_focus_row),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
clist_signals[SELECT_ALL] =
gtk_signal_new ("select_all",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, select_all),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
clist_signals[UNSELECT_ALL] =
gtk_signal_new ("unselect_all",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, unselect_all),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
clist_signals[UNDO_SELECTION] =
gtk_signal_new ("undo_selection",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, undo_selection),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
clist_signals[START_SELECTION] =
gtk_signal_new ("start_selection",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, start_selection),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
clist_signals[END_SELECTION] =
gtk_signal_new ("end_selection",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, end_selection),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
clist_signals[TOGGLE_ADD_MODE] =
gtk_signal_new ("toggle_add_mode",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, toggle_add_mode),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
clist_signals[EXTEND_SELECTION] =
gtk_signal_new ("extend_selection",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, extend_selection),
- gtk_marshal_NONE__ENUM_FLOAT_BOOL,
+ gtk_marshal_VOID__ENUM_FLOAT_BOOL,
GTK_TYPE_NONE, 3,
GTK_TYPE_SCROLL_TYPE, GTK_TYPE_FLOAT, GTK_TYPE_BOOL);
clist_signals[SCROLL_VERTICAL] =
@@ -649,21 +649,21 @@ gtk_clist_class_init (GtkCListClass *klass)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, scroll_vertical),
- gtk_marshal_NONE__ENUM_FLOAT,
+ gtk_marshal_VOID__ENUM_FLOAT,
GTK_TYPE_NONE, 2, GTK_TYPE_SCROLL_TYPE, GTK_TYPE_FLOAT);
clist_signals[SCROLL_HORIZONTAL] =
gtk_signal_new ("scroll_horizontal",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, scroll_horizontal),
- gtk_marshal_NONE__ENUM_FLOAT,
+ gtk_marshal_VOID__ENUM_FLOAT,
GTK_TYPE_NONE, 2, GTK_TYPE_SCROLL_TYPE, GTK_TYPE_FLOAT);
clist_signals[ABORT_COLUMN_RESIZE] =
gtk_signal_new ("abort_column_resize",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCListClass, abort_column_resize),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, clist_signals, LAST_SIGNAL);
diff --git a/gtk/gtkcolorsel.c b/gtk/gtkcolorsel.c
index 8093a0221..4830f6b65 100644
--- a/gtk/gtkcolorsel.c
+++ b/gtk/gtkcolorsel.c
@@ -1351,7 +1351,7 @@ gtk_color_selection_class_init (GtkColorSelectionClass *klass)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkColorSelectionClass, color_changed),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
diff --git a/gtk/gtkcontainer.c b/gtk/gtkcontainer.c
index 02158eefd..053a6a893 100644
--- a/gtk/gtkcontainer.c
+++ b/gtk/gtkcontainer.c
@@ -172,7 +172,7 @@ gtk_container_class_init (GtkContainerClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkContainerClass, add),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_WIDGET);
container_signals[REMOVE] =
@@ -180,7 +180,7 @@ gtk_container_class_init (GtkContainerClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkContainerClass, remove),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_WIDGET);
container_signals[CHECK_RESIZE] =
@@ -188,7 +188,7 @@ gtk_container_class_init (GtkContainerClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkContainerClass, check_resize),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
container_signals[FOCUS] =
gtk_signal_new ("focus",
@@ -203,7 +203,7 @@ gtk_container_class_init (GtkContainerClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkContainerClass, set_focus_child),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_WIDGET);
gtk_object_class_add_signals (object_class, container_signals, LAST_SIGNAL);
diff --git a/gtk/gtkctree.c b/gtk/gtkctree.c
index b156789b7..9a80d2c76 100644
--- a/gtk/gtkctree.c
+++ b/gtk/gtkctree.c
@@ -391,35 +391,35 @@ gtk_ctree_class_init (GtkCTreeClass *klass)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCTreeClass, tree_select_row),
- gtk_marshal_NONE__POINTER_INT,
+ gtk_marshal_VOID__POINTER_INT,
GTK_TYPE_NONE, 2, GTK_TYPE_CTREE_NODE, GTK_TYPE_INT);
ctree_signals[TREE_UNSELECT_ROW] =
gtk_signal_new ("tree_unselect_row",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCTreeClass, tree_unselect_row),
- gtk_marshal_NONE__POINTER_INT,
+ gtk_marshal_VOID__POINTER_INT,
GTK_TYPE_NONE, 2, GTK_TYPE_CTREE_NODE, GTK_TYPE_INT);
ctree_signals[TREE_EXPAND] =
gtk_signal_new ("tree_expand",
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCTreeClass, tree_expand),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1, GTK_TYPE_CTREE_NODE);
ctree_signals[TREE_COLLAPSE] =
gtk_signal_new ("tree_collapse",
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCTreeClass, tree_collapse),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1, GTK_TYPE_CTREE_NODE);
ctree_signals[TREE_MOVE] =
gtk_signal_new ("tree_move",
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCTreeClass, tree_move),
- gtk_marshal_NONE__POINTER_POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER_POINTER,
GTK_TYPE_NONE, 3, GTK_TYPE_CTREE_NODE,
GTK_TYPE_CTREE_NODE, GTK_TYPE_CTREE_NODE);
ctree_signals[CHANGE_FOCUS_ROW_EXPANSION] =
@@ -428,7 +428,7 @@ gtk_ctree_class_init (GtkCTreeClass *klass)
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCTreeClass,
change_focus_row_expansion),
- gtk_marshal_NONE__ENUM,
+ gtk_marshal_VOID__ENUM,
GTK_TYPE_NONE, 1, GTK_TYPE_CTREE_EXPANSION_TYPE);
gtk_object_class_add_signals (object_class, ctree_signals, LAST_SIGNAL);
diff --git a/gtk/gtkcurve.c b/gtk/gtkcurve.c
index 805507df6..76e5c3091 100644
--- a/gtk/gtkcurve.c
+++ b/gtk/gtkcurve.c
@@ -114,7 +114,7 @@ gtk_curve_class_init (GtkCurveClass *class)
curve_type_changed_signal =
gtk_signal_new ("curve_type_changed", GTK_RUN_FIRST, GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkCurveClass, curve_type_changed),
- gtk_marshal_NONE__NONE, GTK_TYPE_NONE, 0);
+ gtk_marshal_VOID__VOID, GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, &curve_type_changed_signal, 1);
gtk_object_add_arg_type ("GtkCurve::curve_type", GTK_TYPE_CURVE_TYPE,
diff --git a/gtk/gtkdata.c b/gtk/gtkdata.c
index d58e8dbfa..752017802 100644
--- a/gtk/gtkdata.c
+++ b/gtk/gtkdata.c
@@ -77,7 +77,7 @@ gtk_data_class_init (GtkDataClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkDataClass, disconnect),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, data_signals, LAST_SIGNAL);
diff --git a/gtk/gtkeditable.c b/gtk/gtkeditable.c
index 70cf6b881..76ee618fd 100644
--- a/gtk/gtkeditable.c
+++ b/gtk/gtkeditable.c
@@ -150,7 +150,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, changed),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
editable_signals[INSERT_TEXT] =
@@ -158,7 +158,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, insert_text),
- gtk_marshal_NONE__POINTER_INT_POINTER,
+ gtk_marshal_VOID__POINTER_INT_POINTER,
GTK_TYPE_NONE,
3,
GTK_TYPE_STRING,
@@ -170,7 +170,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, delete_text),
- gtk_marshal_NONE__INT_INT,
+ gtk_marshal_VOID__INT_INT,
GTK_TYPE_NONE,
2,
GTK_TYPE_INT,
@@ -181,7 +181,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, activate),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
widget_class->activate_signal = editable_signals[ACTIVATE];
@@ -190,7 +190,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, set_editable),
- gtk_marshal_NONE__BOOL,
+ gtk_marshal_VOID__BOOLEAN,
GTK_TYPE_NONE, 1,
GTK_TYPE_BOOL);
@@ -199,7 +199,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, move_cursor),
- gtk_marshal_NONE__INT_INT,
+ gtk_marshal_VOID__INT_INT,
GTK_TYPE_NONE, 2,
GTK_TYPE_INT,
GTK_TYPE_INT);
@@ -209,7 +209,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, move_word),
- gtk_marshal_NONE__INT,
+ gtk_marshal_VOID__INT,
GTK_TYPE_NONE, 1,
GTK_TYPE_INT);
@@ -218,7 +218,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, move_page),
- gtk_marshal_NONE__INT_INT,
+ gtk_marshal_VOID__INT_INT,
GTK_TYPE_NONE, 2,
GTK_TYPE_INT,
GTK_TYPE_INT);
@@ -228,7 +228,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, move_to_row),
- gtk_marshal_NONE__INT,
+ gtk_marshal_VOID__INT,
GTK_TYPE_NONE, 1,
GTK_TYPE_INT);
@@ -237,7 +237,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, move_to_column),
- gtk_marshal_NONE__INT,
+ gtk_marshal_VOID__INT,
GTK_TYPE_NONE, 1,
GTK_TYPE_INT);
@@ -246,7 +246,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, kill_char),
- gtk_marshal_NONE__INT,
+ gtk_marshal_VOID__INT,
GTK_TYPE_NONE, 1,
GTK_TYPE_INT);
@@ -255,7 +255,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, kill_word),
- gtk_marshal_NONE__INT,
+ gtk_marshal_VOID__INT,
GTK_TYPE_NONE, 1,
GTK_TYPE_INT);
@@ -264,7 +264,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, kill_line),
- gtk_marshal_NONE__INT,
+ gtk_marshal_VOID__INT,
GTK_TYPE_NONE, 1,
GTK_TYPE_INT);
@@ -273,7 +273,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, cut_clipboard),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
editable_signals[COPY_CLIPBOARD] =
@@ -281,7 +281,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, copy_clipboard),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
editable_signals[PASTE_CLIPBOARD] =
@@ -289,7 +289,7 @@ gtk_editable_class_init (GtkEditableClass *class)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkEditableClass, paste_clipboard),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, editable_signals, LAST_SIGNAL);
diff --git a/gtk/gtkenums.h b/gtk/gtkenums.h
index 9f8e1f93d..0fcdf510a 100644
--- a/gtk/gtkenums.h
+++ b/gtk/gtkenums.h
@@ -27,6 +27,8 @@
#ifndef __GTK_ENUMS_H__
#define __GTK_ENUMS_H__
+#include <gobject/gsignal.h>
+
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */
@@ -236,12 +238,12 @@ typedef enum
/* signal run types */
typedef enum /*< flags >*/
{
- GTK_RUN_FIRST = 1 << 0,
- GTK_RUN_LAST = 1 << 1,
+ GTK_RUN_FIRST = G_SIGNAL_RUN_FIRST,
+ GTK_RUN_LAST = G_SIGNAL_RUN_LAST,
GTK_RUN_BOTH = (GTK_RUN_FIRST | GTK_RUN_LAST),
- GTK_RUN_NO_RECURSE = 1 << 2,
- GTK_RUN_ACTION = 1 << 3,
- GTK_RUN_NO_HOOKS = 1 << 4
+ GTK_RUN_NO_RECURSE = G_SIGNAL_NO_RECURSE,
+ GTK_RUN_ACTION = G_SIGNAL_ACTION,
+ GTK_RUN_NO_HOOKS = G_SIGNAL_NO_HOOKS
} GtkSignalRunType;
/* scrolling types */
diff --git a/gtk/gtkhandlebox.c b/gtk/gtkhandlebox.c
index 88d3ef873..e62230bcf 100644
--- a/gtk/gtkhandlebox.c
+++ b/gtk/gtkhandlebox.c
@@ -183,7 +183,7 @@ gtk_handle_box_class_init (GtkHandleBoxClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkHandleBoxClass, child_attached),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_WIDGET);
handle_box_signals[SIGNAL_CHILD_DETACHED] =
@@ -191,7 +191,7 @@ gtk_handle_box_class_init (GtkHandleBoxClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkHandleBoxClass, child_detached),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_WIDGET);
gtk_object_class_add_signals (object_class, handle_box_signals, SIGNAL_LAST);
diff --git a/gtk/gtkhsv.c b/gtk/gtkhsv.c
index 45a286df7..7b1af385e 100644
--- a/gtk/gtkhsv.c
+++ b/gtk/gtkhsv.c
@@ -150,7 +150,7 @@ gtk_hsv_class_init (GtkHSVClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkHSVClass, changed),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, hsv_signals, LAST_SIGNAL);
diff --git a/gtk/gtkiconfactory.c b/gtk/gtkiconfactory.c
index f6541a3d3..ff724d454 100644
--- a/gtk/gtkiconfactory.c
+++ b/gtk/gtkiconfactory.c
@@ -62,7 +62,7 @@ gtk_icon_factory_get_type (void)
object_type = g_type_register_static (G_TYPE_OBJECT,
"GtkIconFactory",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gtk/gtkimcontext.c b/gtk/gtkimcontext.c
index 70b3a6d8f..753937f11 100644
--- a/gtk/gtkimcontext.c
+++ b/gtk/gtkimcontext.c
@@ -76,7 +76,7 @@ gtk_im_context_class_init (GtkIMContextClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkIMContextClass, preedit_start),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
im_context_signals[PREEDIT_END] =
@@ -84,7 +84,7 @@ gtk_im_context_class_init (GtkIMContextClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkIMContextClass, preedit_end),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
im_context_signals[PREEDIT_CHANGED] =
@@ -92,7 +92,7 @@ gtk_im_context_class_init (GtkIMContextClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkIMContextClass, preedit_changed),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
im_context_signals[COMMIT] =
@@ -100,7 +100,7 @@ gtk_im_context_class_init (GtkIMContextClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkIMContextClass, commit),
- gtk_marshal_NONE__STRING,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_STRING);
diff --git a/gtk/gtkinputdialog.c b/gtk/gtkinputdialog.c
index 147ed2090..cf0e96909 100644
--- a/gtk/gtkinputdialog.c
+++ b/gtk/gtkinputdialog.c
@@ -143,7 +143,7 @@ gtk_input_dialog_class_init (GtkInputDialogClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkInputDialogClass, enable_device),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1, GTK_TYPE_POINTER);
input_dialog_signals[DISABLE_DEVICE] =
@@ -151,7 +151,7 @@ gtk_input_dialog_class_init (GtkInputDialogClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkInputDialogClass, disable_device),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1, GTK_TYPE_POINTER);
gtk_object_class_add_signals (object_class, input_dialog_signals,
diff --git a/gtk/gtkitem.c b/gtk/gtkitem.c
index 2d3a73a63..b3b7e0a5e 100644
--- a/gtk/gtkitem.c
+++ b/gtk/gtkitem.c
@@ -89,21 +89,21 @@ gtk_item_class_init (GtkItemClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkItemClass, select),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
item_signals[DESELECT] =
gtk_signal_new ("deselect",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkItemClass, deselect),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
item_signals[TOGGLE] =
gtk_signal_new ("toggle",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkItemClass, toggle),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, item_signals, LAST_SIGNAL);
diff --git a/gtk/gtklabel.c b/gtk/gtklabel.c
index 817c85403..e7fcde574 100644
--- a/gtk/gtklabel.c
+++ b/gtk/gtklabel.c
@@ -79,7 +79,7 @@ gtk_label_get_type (void)
(GInstanceInitFunc) gtk_label_init,
};
- label_type = g_type_register_static (GTK_TYPE_MISC, "GtkLabel", &label_info);
+ label_type = g_type_register_static (GTK_TYPE_MISC, "GtkLabel", &label_info, 0);
}
return label_type;
diff --git a/gtk/gtklayout.c b/gtk/gtklayout.c
index 23e46dfe4..b1b87ea0d 100644
--- a/gtk/gtklayout.c
+++ b/gtk/gtklayout.c
@@ -360,7 +360,7 @@ gtk_layout_get_type (void)
(GInstanceInitFunc) gtk_layout_init,
};
- layout_type = g_type_register_static (GTK_TYPE_CONTAINER, "GtkLayout", &layout_info);
+ layout_type = g_type_register_static (GTK_TYPE_CONTAINER, "GtkLayout", &layout_info, 0);
}
return layout_type;
@@ -400,7 +400,7 @@ gtk_layout_class_init (GtkLayoutClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkLayoutClass, set_scroll_adjustments),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE, 2, GTK_TYPE_ADJUSTMENT, GTK_TYPE_ADJUSTMENT);
}
diff --git a/gtk/gtklist.c b/gtk/gtklist.c
index de3eeb987..1043e147f 100644
--- a/gtk/gtklist.c
+++ b/gtk/gtklist.c
@@ -221,14 +221,14 @@ gtk_list_class_init (GtkListClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListClass, selection_changed),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
list_signals[SELECT_CHILD] =
gtk_signal_new ("select_child",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListClass, select_child),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_WIDGET);
list_signals[UNSELECT_CHILD] =
@@ -236,7 +236,7 @@ gtk_list_class_init (GtkListClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListClass, unselect_child),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_WIDGET);
diff --git a/gtk/gtklistitem.c b/gtk/gtklistitem.c
index 15b6e5479..e4bf4a2ab 100644
--- a/gtk/gtklistitem.c
+++ b/gtk/gtklistitem.c
@@ -120,72 +120,72 @@ gtk_list_item_class_init (GtkListItemClass *class)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListItemClass, toggle_focus_row),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
list_item_signals[SELECT_ALL] =
gtk_signal_new ("select_all",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListItemClass, select_all),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
list_item_signals[UNSELECT_ALL] =
gtk_signal_new ("unselect_all",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListItemClass, unselect_all),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
list_item_signals[UNDO_SELECTION] =
gtk_signal_new ("undo_selection",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListItemClass, undo_selection),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
list_item_signals[START_SELECTION] =
gtk_signal_new ("start_selection",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListItemClass, start_selection),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
list_item_signals[END_SELECTION] =
gtk_signal_new ("end_selection",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListItemClass, end_selection),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
list_item_signals[TOGGLE_ADD_MODE] =
gtk_signal_new ("toggle_add_mode",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListItemClass, toggle_add_mode),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
list_item_signals[EXTEND_SELECTION] =
gtk_signal_new ("extend_selection",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListItemClass, extend_selection),
- gtk_marshal_NONE__ENUM_FLOAT_BOOL,
+ gtk_marshal_VOID__ENUM_FLOAT_BOOL,
GTK_TYPE_NONE, 3,
- GTK_TYPE_ENUM, GTK_TYPE_FLOAT, GTK_TYPE_BOOL);
+ GTK_TYPE_SCROLL_TYPE, GTK_TYPE_FLOAT, GTK_TYPE_BOOL);
list_item_signals[SCROLL_VERTICAL] =
gtk_signal_new ("scroll_vertical",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListItemClass, scroll_vertical),
- gtk_marshal_NONE__ENUM_FLOAT,
- GTK_TYPE_NONE, 2, GTK_TYPE_ENUM, GTK_TYPE_FLOAT);
+ gtk_marshal_VOID__ENUM_FLOAT,
+ GTK_TYPE_NONE, 2, GTK_TYPE_SCROLL_TYPE, GTK_TYPE_FLOAT);
list_item_signals[SCROLL_HORIZONTAL] =
gtk_signal_new ("scroll_horizontal",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListItemClass, scroll_horizontal),
- gtk_marshal_NONE__ENUM_FLOAT,
- GTK_TYPE_NONE, 2, GTK_TYPE_ENUM, GTK_TYPE_FLOAT);
+ gtk_marshal_VOID__ENUM_FLOAT,
+ GTK_TYPE_NONE, 2, GTK_TYPE_SCROLL_TYPE, GTK_TYPE_FLOAT);
gtk_object_class_add_signals (object_class, list_item_signals, LAST_SIGNAL);
diff --git a/gtk/gtkliststore.c b/gtk/gtkliststore.c
index 41ab68ec0..8c861c5c0 100644
--- a/gtk/gtkliststore.c
+++ b/gtk/gtkliststore.c
@@ -89,7 +89,7 @@ gtk_list_store_get_type (void)
NULL
};
- list_store_type = g_type_register_static (GTK_TYPE_OBJECT, "GtkListStore", &list_store_info);
+ list_store_type = g_type_register_static (GTK_TYPE_OBJECT, "GtkListStore", &list_store_info, 0);
g_type_add_interface_static (list_store_type,
GTK_TYPE_TREE_MODEL,
&tree_model_info);
@@ -110,7 +110,7 @@ gtk_list_store_class_init (GtkListStoreClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListStoreClass, node_changed),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE, 2,
GTK_TYPE_POINTER,
GTK_TYPE_POINTER);
@@ -119,7 +119,7 @@ gtk_list_store_class_init (GtkListStoreClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListStoreClass, node_inserted),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE, 2,
GTK_TYPE_POINTER,
GTK_TYPE_POINTER);
@@ -128,7 +128,7 @@ gtk_list_store_class_init (GtkListStoreClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListStoreClass, node_child_toggled),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE, 2,
GTK_TYPE_POINTER,
GTK_TYPE_POINTER);
@@ -137,7 +137,7 @@ gtk_list_store_class_init (GtkListStoreClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkListStoreClass, node_deleted),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_POINTER);
diff --git a/gtk/gtkmain.c b/gtk/gtkmain.c
index 98d74c926..9dde7c3ce 100644
--- a/gtk/gtkmain.c
+++ b/gtk/gtkmain.c
@@ -383,7 +383,7 @@ gtk_init_check (int *argc,
}
if (!modinit_func)
{
- g_warning ("Failed to load module \"%s\": %s",
+ g_message ("Failed to load module \"%s\": %s",
module ? g_module_name (module) : module_name,
g_module_error ());
if (module)
diff --git a/gtk/gtkmarshal.list b/gtk/gtkmarshal.list
index b82fff618..1395f1da1 100644
--- a/gtk/gtkmarshal.list
+++ b/gtk/gtkmarshal.list
@@ -1,17 +1,85 @@
+# see glib-genmarshal(1) for a detailed description of the file format,
+# possible parameter types are:
+# VOID indicates no return type, or no extra
+# parameters. if VOID is used as the parameter
+# list, no additional parameters may be present.
+# BOOLEAN for boolean types (gboolean)
+# CHAR for signed char types (gchar)
+# UCHAR for unsigned char types (guchar)
+# INT for signed integer types (gint)
+# UINT for unsigned integer types (guint)
+# LONG for signed long integer types (glong)
+# ULONG for unsigned long integer types (gulong)
+# ENUM for enumeration types (gint)
+# FLAGS for flag enumeration types (guint)
+# FLOAT for single-precision float types (gfloat)
+# DOUBLE for double-precision float types (gdouble)
+# STRING for string types (gchar*)
+# BOXED for boxed (anonymous but reference counted) types (GBoxed*)
+# POINTER for anonymous pointer types (gpointer)
+# OBJECT for GObject or derived types (GObject*)
+# NONE deprecated alias for VOID
+# BOOL deprecated alias for BOOLEAN
+
+
+BOOLEAN:POINTER
+BOOLEAN:POINTER,INT,INT
+BOOLEAN:POINTER,INT,INT,UINT
+BOOLEAN:POINTER,POINTER,INT,INT
+BOOLEAN:POINTER,STRING,STRING,POINTER
+BOOLEAN:VOID
+ENUM:ENUM
+INT:OBJECT,BOXED,POINTER
+INT:POINTER
+INT:POINTER,CHAR,CHAR
+INT:VOID
+POINTER:POINTER
+POINTER:POINTER,INT
+POINTER:VOID
+VOID:BOOLEAN
+VOID:BOXED
+VOID:BOXED,UINT,FLAGS
+VOID:ENUM
+VOID:ENUM,FLOAT
+VOID:ENUM,FLOAT,BOOLEAN
+VOID:INT
+VOID:INT,INT
+VOID:INT,INT,INT
+VOID:INT,INT,INT,INT
+VOID:INT,INT,POINTER
+VOID:OBJECT
+VOID:POINTER
+VOID:POINTER,INT
+VOID:POINTER,INT,INT,POINTER,UINT,UINT
+VOID:POINTER,INT,POINTER
+VOID:POINTER,POINTER
+VOID:POINTER,POINTER,INT
+VOID:POINTER,POINTER,INT,INT
+VOID:POINTER,POINTER,POINTER
+VOID:POINTER,POINTER,UINT,UINT
+VOID:POINTER,STRING,STRING
+VOID:POINTER,UINT
+VOID:POINTER,UINT,ENUM
+VOID:POINTER,UINT,UINT
+VOID:STRING
+VOID:STRING,INT,POINTER
+VOID:STRING,POINTER
+VOID:UINT
+VOID:UINT,BOXED,UINT,FLAGS,FLAGS
+VOID:UINT,POINTER,UINT,ENUM,ENUM,POINTER
+VOID:UINT,POINTER,UINT,UINT,ENUM
+VOID:UINT,STRING
+VOID:VOID
+
+# deprecated, compatibility aliases:
BOOL:NONE
BOOL:POINTER
-BOOL:POINTER,POINTER,INT,INT
BOOL:POINTER,INT,INT
BOOL:POINTER,INT,INT,UINT
+BOOL:POINTER,POINTER,INT,INT
BOOL:POINTER,STRING,STRING,POINTER
-ENUM:ENUM
INT:NONE
-INT:POINTER
-INT:POINTER,CHAR,CHAR
-INT:OBJECT,BOXED,POINTER
POINTER:NONE
-POINTER:POINTER
-POINTER:POINTER,INT
NONE:BOOL
NONE:BOXED
NONE:ENUM
@@ -25,14 +93,16 @@ NONE:NONE
NONE:OBJECT
NONE:POINTER
NONE:POINTER,INT
+NONE:POINTER,INT,INT,POINTER,UINT,UINT
+NONE:POINTER,INT,POINTER
NONE:POINTER,POINTER
+NONE:POINTER,POINTER,INT
+NONE:POINTER,POINTER,INT,INT
NONE:POINTER,POINTER,POINTER
+NONE:POINTER,POINTER,UINT,UINT
NONE:POINTER,STRING,STRING
NONE:POINTER,UINT
NONE:POINTER,UINT,ENUM
-NONE:POINTER,POINTER,UINT,UINT
-NONE:POINTER,INT,INT,POINTER,UINT,UINT
-NONE:POINTER,UINT,UINT
NONE:POINTER,UINT,UINT
NONE:STRING
NONE:STRING,INT,POINTER
@@ -41,5 +111,4 @@ NONE:UINT
NONE:UINT,POINTER,UINT,ENUM,ENUM,POINTER
NONE:UINT,POINTER,UINT,UINT,ENUM
NONE:UINT,STRING
-NONE:POINTER,POINTER,INT,INT
-NONE:POINTER,POINTER,INT
+VOID:ENUM,FLOAT,BOOL
diff --git a/gtk/gtkmarshalers.list b/gtk/gtkmarshalers.list
index b82fff618..1395f1da1 100644
--- a/gtk/gtkmarshalers.list
+++ b/gtk/gtkmarshalers.list
@@ -1,17 +1,85 @@
+# see glib-genmarshal(1) for a detailed description of the file format,
+# possible parameter types are:
+# VOID indicates no return type, or no extra
+# parameters. if VOID is used as the parameter
+# list, no additional parameters may be present.
+# BOOLEAN for boolean types (gboolean)
+# CHAR for signed char types (gchar)
+# UCHAR for unsigned char types (guchar)
+# INT for signed integer types (gint)
+# UINT for unsigned integer types (guint)
+# LONG for signed long integer types (glong)
+# ULONG for unsigned long integer types (gulong)
+# ENUM for enumeration types (gint)
+# FLAGS for flag enumeration types (guint)
+# FLOAT for single-precision float types (gfloat)
+# DOUBLE for double-precision float types (gdouble)
+# STRING for string types (gchar*)
+# BOXED for boxed (anonymous but reference counted) types (GBoxed*)
+# POINTER for anonymous pointer types (gpointer)
+# OBJECT for GObject or derived types (GObject*)
+# NONE deprecated alias for VOID
+# BOOL deprecated alias for BOOLEAN
+
+
+BOOLEAN:POINTER
+BOOLEAN:POINTER,INT,INT
+BOOLEAN:POINTER,INT,INT,UINT
+BOOLEAN:POINTER,POINTER,INT,INT
+BOOLEAN:POINTER,STRING,STRING,POINTER
+BOOLEAN:VOID
+ENUM:ENUM
+INT:OBJECT,BOXED,POINTER
+INT:POINTER
+INT:POINTER,CHAR,CHAR
+INT:VOID
+POINTER:POINTER
+POINTER:POINTER,INT
+POINTER:VOID
+VOID:BOOLEAN
+VOID:BOXED
+VOID:BOXED,UINT,FLAGS
+VOID:ENUM
+VOID:ENUM,FLOAT
+VOID:ENUM,FLOAT,BOOLEAN
+VOID:INT
+VOID:INT,INT
+VOID:INT,INT,INT
+VOID:INT,INT,INT,INT
+VOID:INT,INT,POINTER
+VOID:OBJECT
+VOID:POINTER
+VOID:POINTER,INT
+VOID:POINTER,INT,INT,POINTER,UINT,UINT
+VOID:POINTER,INT,POINTER
+VOID:POINTER,POINTER
+VOID:POINTER,POINTER,INT
+VOID:POINTER,POINTER,INT,INT
+VOID:POINTER,POINTER,POINTER
+VOID:POINTER,POINTER,UINT,UINT
+VOID:POINTER,STRING,STRING
+VOID:POINTER,UINT
+VOID:POINTER,UINT,ENUM
+VOID:POINTER,UINT,UINT
+VOID:STRING
+VOID:STRING,INT,POINTER
+VOID:STRING,POINTER
+VOID:UINT
+VOID:UINT,BOXED,UINT,FLAGS,FLAGS
+VOID:UINT,POINTER,UINT,ENUM,ENUM,POINTER
+VOID:UINT,POINTER,UINT,UINT,ENUM
+VOID:UINT,STRING
+VOID:VOID
+
+# deprecated, compatibility aliases:
BOOL:NONE
BOOL:POINTER
-BOOL:POINTER,POINTER,INT,INT
BOOL:POINTER,INT,INT
BOOL:POINTER,INT,INT,UINT
+BOOL:POINTER,POINTER,INT,INT
BOOL:POINTER,STRING,STRING,POINTER
-ENUM:ENUM
INT:NONE
-INT:POINTER
-INT:POINTER,CHAR,CHAR
-INT:OBJECT,BOXED,POINTER
POINTER:NONE
-POINTER:POINTER
-POINTER:POINTER,INT
NONE:BOOL
NONE:BOXED
NONE:ENUM
@@ -25,14 +93,16 @@ NONE:NONE
NONE:OBJECT
NONE:POINTER
NONE:POINTER,INT
+NONE:POINTER,INT,INT,POINTER,UINT,UINT
+NONE:POINTER,INT,POINTER
NONE:POINTER,POINTER
+NONE:POINTER,POINTER,INT
+NONE:POINTER,POINTER,INT,INT
NONE:POINTER,POINTER,POINTER
+NONE:POINTER,POINTER,UINT,UINT
NONE:POINTER,STRING,STRING
NONE:POINTER,UINT
NONE:POINTER,UINT,ENUM
-NONE:POINTER,POINTER,UINT,UINT
-NONE:POINTER,INT,INT,POINTER,UINT,UINT
-NONE:POINTER,UINT,UINT
NONE:POINTER,UINT,UINT
NONE:STRING
NONE:STRING,INT,POINTER
@@ -41,5 +111,4 @@ NONE:UINT
NONE:UINT,POINTER,UINT,ENUM,ENUM,POINTER
NONE:UINT,POINTER,UINT,UINT,ENUM
NONE:UINT,STRING
-NONE:POINTER,POINTER,INT,INT
-NONE:POINTER,POINTER,INT
+VOID:ENUM,FLOAT,BOOL
diff --git a/gtk/gtkmenuitem.c b/gtk/gtkmenuitem.c
index e27fa6d13..b4e0ba454 100644
--- a/gtk/gtkmenuitem.c
+++ b/gtk/gtkmenuitem.c
@@ -101,7 +101,7 @@ gtk_menu_item_get_type (void)
(GInstanceInitFunc) gtk_menu_item_init,
};
- menu_item_type = g_type_register_static (GTK_TYPE_ITEM, "GtkMenuItem", &menu_item_info);
+ menu_item_type = g_type_register_static (GTK_TYPE_ITEM, "GtkMenuItem", &menu_item_info, 0);
}
return menu_item_type;
@@ -127,7 +127,7 @@ gtk_menu_item_class_init (GtkMenuItemClass *klass)
GTK_RUN_FIRST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkMenuItemClass, activate),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
menu_item_signals[ACTIVATE_ITEM] =
diff --git a/gtk/gtkmenushell.c b/gtk/gtkmenushell.c
index 38a717e49..a8ced1698 100644
--- a/gtk/gtkmenushell.c
+++ b/gtk/gtkmenushell.c
@@ -192,21 +192,21 @@ gtk_menu_shell_class_init (GtkMenuShellClass *klass)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkMenuShellClass, deactivate),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
menu_shell_signals[SELECTION_DONE] =
gtk_signal_new ("selection-done",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkMenuShellClass, selection_done),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
menu_shell_signals[MOVE_CURRENT] =
gtk_signal_new ("move_current",
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkMenuShellClass, move_current),
- gtk_marshal_NONE__ENUM,
+ gtk_marshal_VOID__ENUM,
GTK_TYPE_NONE, 1,
GTK_TYPE_MENU_DIRECTION_TYPE);
menu_shell_signals[ACTIVATE_CURRENT] =
@@ -214,7 +214,7 @@ gtk_menu_shell_class_init (GtkMenuShellClass *klass)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkMenuShellClass, activate_current),
- gtk_marshal_NONE__BOOL,
+ gtk_marshal_VOID__BOOLEAN,
GTK_TYPE_NONE, 1,
GTK_TYPE_BOOL);
menu_shell_signals[CANCEL] =
@@ -222,7 +222,7 @@ gtk_menu_shell_class_init (GtkMenuShellClass *klass)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkMenuShellClass, cancel),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, menu_shell_signals, LAST_SIGNAL);
diff --git a/gtk/gtkmodelsimple.c b/gtk/gtkmodelsimple.c
index e44aee4ca..1d32e48f1 100644
--- a/gtk/gtkmodelsimple.c
+++ b/gtk/gtkmodelsimple.c
@@ -18,7 +18,6 @@
*/
#include "gtkmodelsimple.h"
-#include "gtkmarshal.h"
#include "gtksignal.h"
enum {
NODE_CHANGED,
@@ -98,7 +97,7 @@ gtk_model_simple_get_type (void)
NULL
};
- model_simple_type = g_type_register_static (GTK_TYPE_TREE_MODEL, "GtkModelSimple", &model_simple_info);
+ model_simple_type = g_type_register_static (GTK_TYPE_TREE_MODEL, "GtkModelSimple", &model_simple_info, 0);
g_type_add_interface_static (model_simple_type,
GTK_TYPE_TREE_MODEL,
&tree_model_info);
@@ -125,7 +124,7 @@ gtk_model_simple_class_init (GtkModelSimpleClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkModelSimpleClass, node_changed),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE, 2,
GTK_TYPE_POINTER,
GTK_TYPE_POINTER);
@@ -134,7 +133,7 @@ gtk_model_simple_class_init (GtkModelSimpleClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkModelSimpleClass, node_inserted),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE, 2,
GTK_TYPE_POINTER,
GTK_TYPE_POINTER);
@@ -143,7 +142,7 @@ gtk_model_simple_class_init (GtkModelSimpleClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkModelSimpleClass, node_child_toggled),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE, 2,
GTK_TYPE_POINTER,
GTK_TYPE_POINTER);
@@ -152,7 +151,7 @@ gtk_model_simple_class_init (GtkModelSimpleClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkModelSimpleClass, node_deleted),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_POINTER);
@@ -161,7 +160,7 @@ gtk_model_simple_class_init (GtkModelSimpleClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
0,
- gtk_marshal_INT__NONE,
+ gtk_marshal_INT__VOID,
GTK_TYPE_INT, 0);
model_simple_signals[GET_NODE] =
gtk_signal_new ("get_node",
@@ -184,7 +183,7 @@ gtk_model_simple_class_init (GtkModelSimpleClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
0,
- gtk_marshal_NONE__POINTER_INT_POINTER,
+ gtk_marshal_VOID__POINTER_INT_POINTER,
GTK_TYPE_NONE, 3,
GTK_TYPE_POINTER,
GTK_TYPE_INT,
@@ -194,7 +193,7 @@ gtk_model_simple_class_init (GtkModelSimpleClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
0,
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_POINTER);
model_simple_signals[NODE_CHILDREN] =
diff --git a/gtk/gtknotebook.c b/gtk/gtknotebook.c
index 839c77811..0cb79802e 100644
--- a/gtk/gtknotebook.c
+++ b/gtk/gtknotebook.c
@@ -273,7 +273,7 @@ gtk_notebook_class_init (GtkNotebookClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkNotebookClass, switch_page),
- gtk_marshal_NONE__POINTER_UINT,
+ gtk_marshal_VOID__POINTER_UINT,
GTK_TYPE_NONE, 2,
GTK_TYPE_POINTER,
GTK_TYPE_UINT);
diff --git a/gtk/gtkobject.c b/gtk/gtkobject.c
index cefeddfc5..c1df707cb 100644
--- a/gtk/gtkobject.c
+++ b/gtk/gtkobject.c
@@ -95,7 +95,7 @@ gtk_object_get_type (void)
(GInstanceInitFunc) gtk_object_init,
};
- object_type = g_type_register_static (G_TYPE_OBJECT, "GtkObject", &object_info);
+ object_type = g_type_register_static (G_TYPE_OBJECT, "GtkObject", &object_info, 0);
}
return object_type;
@@ -161,10 +161,10 @@ gtk_object_class_init (GtkObjectClass *class)
object_signals[DESTROY] =
gtk_signal_new ("destroy",
- GTK_RUN_LAST | GTK_RUN_NO_HOOKS,
+ G_SIGNAL_RUN_CLEANUP | G_SIGNAL_NO_RECURSE | GTK_RUN_NO_HOOKS,
GTK_CLASS_TYPE (class),
GTK_SIGNAL_OFFSET (GtkObjectClass, destroy),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (class, object_signals, LAST_SIGNAL);
@@ -201,13 +201,10 @@ gtk_object_destroy (GtkObject *object)
if (!GTK_OBJECT_DESTROYED (object))
{
/* need to hold a reference count around all class method
- * invocations. we guard against reinvocations during
- * destruction with the GTK_DESTROYED flag.
+ * invocations.
*/
gtk_object_ref (object);
- GTK_OBJECT_SET_FLAGS (object, GTK_DESTROYED);
G_OBJECT_GET_CLASS (object)->shutdown (G_OBJECT (object));
- GTK_OBJECT_UNSET_FLAGS (object, GTK_DESTROYED);
gtk_object_unref (object);
}
}
@@ -217,7 +214,17 @@ gtk_object_shutdown (GObject *gobject)
{
GtkObject *object = GTK_OBJECT (gobject);
- gtk_signal_emit (object, object_signals[DESTROY]);
+ /* guard against reinvocations during
+ * destruction with the GTK_DESTROYED flag.
+ */
+ if (!GTK_OBJECT_DESTROYED (object))
+ {
+ GTK_OBJECT_SET_FLAGS (object, GTK_DESTROYED);
+
+ gtk_signal_emit (object, object_signals[DESTROY]);
+
+ GTK_OBJECT_UNSET_FLAGS (object, GTK_DESTROYED);
+ }
G_OBJECT_CLASS (parent_class)->shutdown (gobject);
}
@@ -225,8 +232,7 @@ gtk_object_shutdown (GObject *gobject)
static void
gtk_object_real_destroy (GtkObject *object)
{
- if (GTK_OBJECT_CONNECTED (object))
- gtk_signal_handlers_destroy (object);
+ g_signal_handlers_destroy (G_OBJECT (object));
}
static void
diff --git a/gtk/gtkobject.h b/gtk/gtkobject.h
index 3b7947a64..7c819d3a4 100644
--- a/gtk/gtkobject.h
+++ b/gtk/gtkobject.h
@@ -64,7 +64,7 @@ typedef enum
{
GTK_DESTROYED = 1 << 0,
GTK_FLOATING = 1 << 1,
- GTK_CONNECTED = 1 << 2,
+ GTK_RESERVED = 1 << 2,
GTK_CONSTRUCTED = 1 << 3
} GtkObjectFlags;
diff --git a/gtk/gtkplug.c b/gtk/gtkplug.c
index 78be5ca13..420b53a8c 100644
--- a/gtk/gtkplug.c
+++ b/gtk/gtkplug.c
@@ -79,7 +79,7 @@ gtk_plug_get_type ()
(GInstanceInitFunc) gtk_plug_init,
};
- plug_type = g_type_register_static (GTK_TYPE_WINDOW, "GtkPlug", &plug_info);
+ plug_type = g_type_register_static (GTK_TYPE_WINDOW, "GtkPlug", &plug_info, 0);
}
return plug_type;
diff --git a/gtk/gtkrc.c b/gtk/gtkrc.c
index 324e8d3a5..5626ad4ff 100644
--- a/gtk/gtkrc.c
+++ b/gtk/gtkrc.c
@@ -733,7 +733,7 @@ gtk_rc_style_get_type (void)
object_type = g_type_register_static (G_TYPE_OBJECT,
"GtkRcStyle",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gtk/gtksignal.c b/gtk/gtksignal.c
index 5cfc38cfe..004b7293f 100644
--- a/gtk/gtksignal.c
+++ b/gtk/gtksignal.c
@@ -8,7 +8,7 @@
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
@@ -17,2003 +17,427 @@
* Boston, MA 02111-1307, USA.
*/
-/*
- * Modified by the GTK+ Team and others 1997-2000. See the AUTHORS
- * file for a list of people on the GTK+ Team. See the ChangeLog
- * files for a list of changes. These files are distributed with
- * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
- */
-
-#include <stdarg.h>
-#include <string.h>
-#include <stdio.h>
-#include "gtksignal.h"
-#include "gtkargcollector.c"
-
-
-#define SIGNAL_BLOCK_SIZE (100)
-#define HANDLER_BLOCK_SIZE (200)
-#define EMISSION_BLOCK_SIZE (100)
-#define DISCONNECT_INFO_BLOCK_SIZE (64)
-#define MAX_SIGNAL_PARAMS (31)
-
-enum
-{
- EMISSION_CONTINUE,
- EMISSION_RESTART,
- EMISSION_DONE
-};
-
-#define GTK_RUN_TYPE(x) ((x) & GTK_RUN_BOTH)
-
-
-typedef struct _GtkSignal GtkSignal;
-typedef struct _GtkSignalHash GtkSignalHash;
-typedef struct _GtkHandler GtkHandler;
-typedef struct _GtkEmission GtkEmission;
-typedef struct _GtkEmissionHookData GtkEmissionHookData;
-typedef struct _GtkDisconnectInfo GtkDisconnectInfo;
-
-typedef void (*GtkSignalMarshaller0) (GtkObject *object,
- gpointer data);
-
-struct _GtkSignal
-{
- guint signal_id;
- GtkType object_type;
- gchar *name;
- guint function_offset;
- GtkSignalMarshaller marshaller;
- GtkType return_val;
- guint signal_flags : 16;
- guint nparams : 16;
- GtkType *params;
- GHookList *hook_list;
-};
-
-struct _GtkSignalHash
-{
- GtkType object_type;
- GQuark quark;
- guint signal_id;
-};
-
-struct _GtkHandler
-{
- guint id;
- GtkHandler *next;
- GtkHandler *prev;
- guint blocked : 20;
- guint object_signal : 1;
- guint after : 1;
- guint no_marshal : 1;
- guint16 ref_count;
- guint16 signal_id;
- GtkSignalFunc func;
- gpointer func_data;
- GtkSignalDestroy destroy_func;
-};
-
-struct _GtkEmission
-{
- GtkObject *object;
- guint16 signal_id;
- guint in_hook : 1;
- GtkEmission *next;
-};
-
-struct _GtkEmissionHookData
-{
- GtkObject *object;
- guint signal_id;
- guint n_params;
- GtkArg *params;
-};
+#include "gtksignal.h"
+#include "gtkargcollector.c"
+#include "gtkmarshal.c"
-struct _GtkDisconnectInfo
-{
- GtkObject *object1;
- guint disconnect_handler1;
- guint signal_handler;
- GtkObject *object2;
- guint disconnect_handler2;
-};
-
-
-static guint gtk_signal_hash (gconstpointer h);
-static gint gtk_signal_compare (gconstpointer h1,
- gconstpointer h2);
-static GtkHandler* gtk_signal_handler_new (void);
-static void gtk_signal_handler_ref (GtkHandler *handler);
-static void gtk_signal_handler_unref (GtkHandler *handler,
- GtkObject *object);
-static void gtk_signal_handler_insert (GtkObject *object,
- GtkHandler *handler);
-static void gtk_signal_real_emit (GtkObject *object,
- guint signal_id,
- GtkArg *params);
-static guint gtk_signal_connect_by_type (GtkObject *object,
- guint signal_id,
- GtkSignalFunc func,
- gpointer func_data,
- GtkSignalDestroy destroy_func,
- gint object_signal,
- gint after,
- gint no_marshal);
-static guint gtk_alive_disconnecter (GtkDisconnectInfo *info);
-static GtkEmission* gtk_emission_new (void);
-static void gtk_emission_add (GtkEmission **emissions,
- GtkObject *object,
- guint signal_type);
-static void gtk_emission_remove (GtkEmission **emissions,
- GtkObject *object,
- guint signal_type);
-static gint gtk_emission_check (GtkEmission *emissions,
- GtkObject *object,
- guint signal_type);
-static gint gtk_handlers_run (GtkHandler *handlers,
- GtkSignal *signal,
- GtkObject *object,
- GtkArg *params,
- gint after);
-static gboolean gtk_emission_hook_marshaller (GHook *hook,
- gpointer data);
-static gboolean gtk_signal_collect_params (GtkArg *params,
- guint nparams,
- GtkType *param_types,
- GtkType return_type,
- va_list var_args);
-
-#define LOOKUP_SIGNAL_ID(signal_id) ( \
- signal_id > 0 && signal_id < _gtk_private_n_signals ? \
- (GtkSignal*) _gtk_private_signals + signal_id : \
- (GtkSignal*) 0 \
-)
-
-
-static GtkSignalMarshal global_marshaller = NULL;
-static GtkSignalDestroy global_destroy_notify = NULL;
-
-static guint gtk_handler_id = 1;
-static guint gtk_handler_quark = 0;
-static GHashTable *gtk_signal_hash_table = NULL;
-#ifdef G_OS_WIN32
-#define EXPORT __declspec(dllexport)
-#else
-#define EXPORT
-#endif
-EXPORT GtkSignal *_gtk_private_signals = NULL;
-EXPORT guint _gtk_private_n_signals = 0;
-static GMemChunk *gtk_signal_hash_mem_chunk = NULL;
-static GMemChunk *gtk_disconnect_info_mem_chunk = NULL;
-static GtkHandler *gtk_handler_free_list = NULL;
-static GtkEmission *gtk_free_emissions = NULL;
-
-
-
-static GtkEmission *current_emissions = NULL;
-static GtkEmission *stop_emissions = NULL;
-static GtkEmission *restart_emissions = NULL;
-
-static GtkSignal*
-gtk_signal_next_and_invalidate (void)
-{
- static guint gtk_n_free_signals = 0;
- register GtkSignal *signal;
- register guint new_signal_id;
-
- /* don't keep *any* GtkSignal pointers across invokation of this function!!!
- */
-
- if (gtk_n_free_signals == 0)
- {
- register guint i;
- register guint size;
-
- /* nearest pow
- */
- size = _gtk_private_n_signals + SIGNAL_BLOCK_SIZE;
- size *= sizeof (GtkSignal);
- i = 1;
- while (i < size)
- i <<= 1;
- size = i;
-
- _gtk_private_signals = g_realloc (_gtk_private_signals, size);
-
- gtk_n_free_signals = size / sizeof (GtkSignal) - _gtk_private_n_signals;
-
- memset (_gtk_private_signals + _gtk_private_n_signals, 0, gtk_n_free_signals * sizeof (GtkSignal));
- }
-
- new_signal_id = _gtk_private_n_signals++;
- gtk_n_free_signals--;
- g_assert (_gtk_private_n_signals < 65535);
-
- signal = LOOKUP_SIGNAL_ID (new_signal_id);
- if (signal)
- signal->signal_id = new_signal_id;
-
- return signal;
-}
-
-static inline GtkHandler*
-gtk_signal_get_handlers (GtkObject *object,
- guint signal_id)
-{
- GtkHandler *handlers;
-
- handlers = gtk_object_get_data_by_id (object, gtk_handler_quark);
-
- while (handlers)
- {
- if (handlers->signal_id == signal_id)
- return handlers;
- handlers = handlers->next;
- }
-
- return NULL;
-}
+/* the real parameter limit is of course given by GSignal, bu we need
+ * an upper limit for the implementations. so this should be adjusted
+ * with any future changes on the GSignal side of things.
+ */
+#define SIGNAL_MAX_PARAMS 12
-void
-gtk_signal_init (void)
-{
- if (!gtk_handler_quark)
- {
- GtkSignal *zero;
-
- zero = gtk_signal_next_and_invalidate ();
- g_assert (zero == NULL);
-
- gtk_handler_quark = g_quark_from_static_string ("gtk-signal-handlers");
-
- gtk_signal_hash_mem_chunk =
- g_mem_chunk_new ("GtkSignalHash mem chunk",
- sizeof (GtkSignalHash),
- sizeof (GtkSignalHash) * SIGNAL_BLOCK_SIZE,
- G_ALLOC_ONLY);
- gtk_disconnect_info_mem_chunk =
- g_mem_chunk_new ("GtkDisconnectInfo mem chunk",
- sizeof (GtkDisconnectInfo),
- sizeof (GtkDisconnectInfo) * DISCONNECT_INFO_BLOCK_SIZE,
- G_ALLOC_AND_FREE);
- gtk_handler_free_list = NULL;
- gtk_free_emissions = NULL;
-
- gtk_signal_hash_table = g_hash_table_new (gtk_signal_hash,
- gtk_signal_compare);
- }
-}
+/* --- functions --- */
guint
-gtk_signal_newv (const gchar *r_name,
+gtk_signal_newv (const gchar *name,
GtkSignalRunType signal_flags,
- GtkType object_type,
- guint function_offset,
+ GtkType object_type,
+ guint function_offset,
GtkSignalMarshaller marshaller,
- GtkType return_val,
- guint nparams,
- GtkType *params)
+ GtkType return_val,
+ guint n_params,
+ GtkType *params)
{
- GtkSignal *signal;
- GtkSignalHash *hash;
- GQuark quark;
- guint i;
- gchar *name;
-
- g_return_val_if_fail (r_name != NULL, 0);
- g_return_val_if_fail (marshaller != NULL, 0);
- g_return_val_if_fail (nparams < MAX_SIGNAL_PARAMS, 0);
- if (nparams)
- g_return_val_if_fail (params != NULL, 0);
-
- if (!gtk_handler_quark)
- gtk_signal_init ();
-
-
- name = g_strdup (r_name);
- g_strdelimit (name, NULL, '_');
-
- quark = gtk_signal_lookup (name, object_type);
- if (quark)
- {
- g_warning ("gtk_signal_newv(): signal \"%s\" already exists in the `%s' class ancestry\n",
- r_name,
- gtk_type_name (object_type));
- g_free (name);
- return 0;
- }
-
- if (return_val != GTK_TYPE_NONE &&
- (signal_flags & GTK_RUN_BOTH) == GTK_RUN_FIRST)
- {
- g_warning ("gtk_signal_newv(): signal \"%s\" - return value `%s' incompatible with GTK_RUN_FIRST",
- name, gtk_type_name (return_val));
- g_free (name);
- return 0;
- }
-
- signal = gtk_signal_next_and_invalidate ();
-
- /* signal->signal_id already set */
+ GClosure *closure;
- signal->object_type = object_type;
- signal->name = name;
- signal->function_offset = function_offset;
- signal->marshaller = marshaller;
- signal->return_val = return_val;
- signal->signal_flags = signal_flags;
- signal->nparams = nparams;
- signal->hook_list = NULL;
+ g_return_val_if_fail (n_params < SIGNAL_MAX_PARAMS, 0);
- if (nparams > 0)
- {
- signal->params = g_new (GtkType, nparams);
-
- for (i = 0; i < nparams; i++)
- signal->params[i] = params[i];
- }
- else
- signal->params = NULL;
-
- /* insert "signal_name" into hash table
- */
- hash = g_chunk_new (GtkSignalHash, gtk_signal_hash_mem_chunk);
- hash->object_type = object_type;
- hash->quark = g_quark_from_string (signal->name);
- hash->signal_id = signal->signal_id;
- g_hash_table_insert (gtk_signal_hash_table, hash, GUINT_TO_POINTER (hash->signal_id));
-
- /* insert "signal-name" into hash table
- */
- g_strdelimit (signal->name, NULL, '-');
- quark = g_quark_from_static_string (signal->name);
- if (quark != hash->quark)
- {
- hash = g_chunk_new (GtkSignalHash, gtk_signal_hash_mem_chunk);
- hash->object_type = object_type;
- hash->quark = quark;
- hash->signal_id = signal->signal_id;
- g_hash_table_insert (gtk_signal_hash_table, hash, GUINT_TO_POINTER (hash->signal_id));
- }
+ closure = g_signal_type_closure_new (object_type, function_offset);
- return signal->signal_id;
+ return g_signal_newv (name, object_type, signal_flags, closure, NULL, marshaller, return_val, n_params, params);
}
guint
-gtk_signal_new (const gchar *name,
+gtk_signal_new (const gchar *name,
GtkSignalRunType signal_flags,
- GtkType object_type,
- guint function_offset,
+ GtkType object_type,
+ guint function_offset,
GtkSignalMarshaller marshaller,
- GtkType return_val,
- guint nparams,
+ GtkType return_val,
+ guint n_params,
...)
{
GtkType *params;
- guint i;
- va_list args;
guint signal_id;
- g_return_val_if_fail (nparams < MAX_SIGNAL_PARAMS, 0);
-
- if (nparams > 0)
+ if (n_params)
{
- params = g_new (GtkType, nparams);
-
- va_start (args, nparams);
+ va_list args;
+ guint i;
- for (i = 0; i < nparams; i++)
+ params = g_new (GtkType, n_params);
+ va_start (args, n_params);
+ for (i = 0; i < n_params; i++)
params[i] = va_arg (args, GtkType);
-
va_end (args);
}
else
params = NULL;
-
signal_id = gtk_signal_newv (name,
signal_flags,
object_type,
function_offset,
marshaller,
return_val,
- nparams,
+ n_params,
params);
-
g_free (params);
return signal_id;
}
-guint
-gtk_signal_lookup (const gchar *name,
- GtkType object_type)
-{
- GtkSignalHash hash;
- GtkType lookup_type;
- gpointer class = NULL;
-
- g_return_val_if_fail (name != NULL, 0);
- g_return_val_if_fail (GTK_TYPE_IS_OBJECT (object_type), 0);
-
- relookup:
-
- lookup_type = object_type;
- hash.quark = g_quark_try_string (name);
- if (hash.quark)
- {
- while (lookup_type)
- {
- guint signal_id;
-
- hash.object_type = lookup_type;
-
- signal_id = GPOINTER_TO_UINT (g_hash_table_lookup (gtk_signal_hash_table, &hash));
- if (signal_id)
- return signal_id;
-
- lookup_type = gtk_type_parent (lookup_type);
- }
- }
-
- if (!class)
- {
- class = gtk_type_class (object_type);
- goto relookup;
- }
-
- return 0;
-}
-
-GtkSignalQuery*
-gtk_signal_query (guint signal_id)
-{
- GtkSignalQuery *query;
- GtkSignal *signal;
-
- g_return_val_if_fail (signal_id >= 1, NULL);
-
- signal = LOOKUP_SIGNAL_ID (signal_id);
- if (signal)
- {
- query = g_new (GtkSignalQuery, 1);
-
- query->object_type = signal->object_type;
- query->signal_id = signal_id;
- query->signal_name = signal->name;
- query->is_user_signal = signal->function_offset == 0;
- query->signal_flags = signal->signal_flags;
- query->return_val = signal->return_val;
- query->nparams = signal->nparams;
- query->params = signal->params;
- }
- else
- query = NULL;
-
- return query;
-}
-
-gchar*
-gtk_signal_name (guint signal_id)
-{
- GtkSignal *signal;
-
- g_return_val_if_fail (signal_id >= 1, NULL);
-
- signal = LOOKUP_SIGNAL_ID (signal_id);
- if (signal)
- return signal->name;
-
- return NULL;
-}
-
void
-gtk_signal_emitv (GtkObject *object,
- guint signal_id,
- GtkArg *params)
+gtk_signal_emit_stop_by_name (GtkObject *object,
+ const gchar *name)
{
- GtkSignal *signal;
-
- g_return_if_fail (object != NULL);
- g_return_if_fail (signal_id >= 1);
-
- signal = LOOKUP_SIGNAL_ID (signal_id);
- g_return_if_fail (signal != NULL);
- g_return_if_fail (gtk_type_is_a (GTK_OBJECT_TYPE (object), signal->object_type));
-
- if (signal->nparams > 0)
- g_return_if_fail (params != NULL);
-
- gtk_signal_real_emit (object, signal_id, params);
-}
-
-void
-gtk_signal_emit (GtkObject *object,
- guint signal_id,
- ...)
-{
- GtkSignal *signal;
- va_list args;
- GtkArg params[MAX_SIGNAL_PARAMS + 1];
- gboolean abort;
-
- g_return_if_fail (object != NULL);
- g_return_if_fail (signal_id >= 1);
-
- signal = LOOKUP_SIGNAL_ID (signal_id);
- g_return_if_fail (signal != NULL);
- g_return_if_fail (gtk_type_is_a (GTK_OBJECT_TYPE (object), signal->object_type));
-
- va_start (args, signal_id);
- abort = gtk_signal_collect_params (params,
- signal->nparams,
- signal->params,
- signal->return_val,
- args);
- va_end (args);
-
- if (!abort)
- gtk_signal_real_emit (object, signal_id, params);
-}
-
-void
-gtk_signal_emitv_by_name (GtkObject *object,
- const gchar *name,
- GtkArg *params)
-{
- guint signal_id;
-
- g_return_if_fail (object != NULL);
- g_return_if_fail (name != NULL);
- g_return_if_fail (params != NULL);
-
- signal_id = gtk_signal_lookup (name, GTK_OBJECT_TYPE (object));
+ g_return_if_fail (GTK_IS_OBJECT (object));
- if (signal_id >= 1)
- {
- GtkSignal *signal;
-
- signal = LOOKUP_SIGNAL_ID (signal_id);
- g_return_if_fail (signal != NULL);
- g_return_if_fail (gtk_type_is_a (GTK_OBJECT_TYPE (object), signal->object_type));
-
- gtk_signal_real_emit (object, signal_id, params);
- }
- else
- {
- g_warning ("gtk_signal_emitv_by_name(): could not find signal \"%s\" in the `%s' class ancestry",
- name,
- gtk_type_name (GTK_OBJECT_TYPE (object)));
- }
+ g_signal_stop_emission (object, g_signal_lookup (name, G_OBJECT_TYPE (object)));
}
void
-gtk_signal_emit_by_name (GtkObject *object,
- const gchar *name,
- ...)
+gtk_signal_connect_object_while_alive (GtkObject *object,
+ const gchar *signal,
+ GtkSignalFunc func,
+ GtkObject *alive_object)
{
- guint signal_id;
-
- g_return_if_fail (object != NULL);
- g_return_if_fail (name != NULL);
-
- signal_id = gtk_signal_lookup (name, GTK_OBJECT_TYPE (object));
-
- if (signal_id >= 1)
- {
- GtkSignal *signal;
- GtkArg params[MAX_SIGNAL_PARAMS + 1];
- va_list args;
- gboolean abort;
-
- signal = LOOKUP_SIGNAL_ID (signal_id);
- g_return_if_fail (signal != NULL);
- g_return_if_fail (gtk_type_is_a (GTK_OBJECT_TYPE (object), signal->object_type));
-
- va_start (args, name);
- abort = gtk_signal_collect_params (params,
- signal->nparams,
- signal->params,
- signal->return_val,
- args);
- va_end (args);
-
- if (!abort)
- gtk_signal_real_emit (object, signal_id, params);
- }
- else
- {
- g_warning ("gtk_signal_emit_by_name(): could not find signal \"%s\" in the `%s' class ancestry",
- name,
- gtk_type_name (GTK_OBJECT_TYPE (object)));
- }
-}
-
-void
-gtk_signal_emit_stop (GtkObject *object,
- guint signal_id)
-{
- gint state;
-
- g_return_if_fail (object != NULL);
- g_return_if_fail (signal_id >= 1);
+ g_return_if_fail (GTK_IS_OBJECT (object));
- state = gtk_emission_check (current_emissions, object, signal_id);
- if (state > 1)
- g_warning ("gtk_signal_emit_stop(): emission (%u) for object `%s' cannot be stopped from emission hook",
- signal_id,
- gtk_type_name (GTK_OBJECT_TYPE (object)));
- else if (state)
- {
- if (!gtk_emission_check (stop_emissions, object, signal_id))
- gtk_emission_add (&stop_emissions, object, signal_id);
- }
- else
- g_warning ("gtk_signal_emit_stop(): no current emission (%u) for object `%s'",
- signal_id,
- gtk_type_name (GTK_OBJECT_TYPE (object)));
+ g_signal_connect_closure (object,
+ g_signal_lookup (signal, G_OBJECT_TYPE (object)),
+ g_cclosure_new_object_swap (func, alive_object),
+ FALSE);
}
void
-gtk_signal_emit_stop_by_name (GtkObject *object,
- const gchar *name)
+gtk_signal_connect_while_alive (GtkObject *object,
+ const gchar *signal,
+ GtkSignalFunc func,
+ gpointer func_data,
+ GtkObject *alive_object)
{
- guint signal_id;
-
- g_return_if_fail (object != NULL);
- g_return_if_fail (name != NULL);
-
- signal_id = gtk_signal_lookup (name, GTK_OBJECT_TYPE (object));
- if (signal_id)
- gtk_signal_emit_stop (object, signal_id);
- else
- g_warning ("gtk_signal_emit_stop_by_name(): could not find signal \"%s\" in the `%s' class ancestry",
- name,
- gtk_type_name (GTK_OBJECT_TYPE (object)));
-}
+ GClosure *closure;
-guint
-gtk_signal_n_emissions (GtkObject *object,
- guint signal_id)
-{
- GtkEmission *emission;
- guint n;
-
- g_return_val_if_fail (object != NULL, 0);
- g_return_val_if_fail (GTK_IS_OBJECT (object), 0);
-
- n = 0;
- for (emission = current_emissions; emission; emission = emission->next)
- {
- if (emission->object == object && emission->signal_id == signal_id)
- n++;
- }
-
- return n;
-}
+ g_return_if_fail (GTK_IS_OBJECT (object));
-guint
-gtk_signal_n_emissions_by_name (GtkObject *object,
- const gchar *name)
-{
- guint signal_id;
- guint n;
-
- g_return_val_if_fail (object != NULL, 0);
- g_return_val_if_fail (GTK_IS_OBJECT (object), 0);
- g_return_val_if_fail (name != NULL, 0);
-
- signal_id = gtk_signal_lookup (name, GTK_OBJECT_TYPE (object));
- if (signal_id)
- n = gtk_signal_n_emissions (object, signal_id);
- else
- {
- g_warning ("gtk_signal_n_emissions_by_name(): could not find signal \"%s\" in the `%s' class ancestry",
- name,
- gtk_type_name (GTK_OBJECT_TYPE (object)));
- n = 0;
- }
-
- return n;
+ closure = g_cclosure_new (func, func_data, NULL);
+ g_object_watch_closure (G_OBJECT (alive_object), closure);
+ g_signal_connect_closure (object,
+ g_signal_lookup (signal, G_OBJECT_TYPE (object)),
+ closure,
+ FALSE);
}
guint
-gtk_signal_connect (GtkObject *object,
- const gchar *name,
- GtkSignalFunc func,
- gpointer func_data)
-{
- guint signal_id;
-
- g_return_val_if_fail (object != NULL, 0);
- g_return_val_if_fail (GTK_IS_OBJECT (object), 0);
-
- signal_id = gtk_signal_lookup (name, GTK_OBJECT_TYPE (object));
- if (!signal_id)
- {
- g_warning ("gtk_signal_connect(): could not find signal \"%s\" in the `%s' class ancestry",
- name,
- gtk_type_name (GTK_OBJECT_TYPE (object)));
- return 0;
- }
-
- return gtk_signal_connect_by_type (object, signal_id,
- func, func_data, NULL,
- FALSE, FALSE, FALSE);
-}
-
-guint
-gtk_signal_connect_after (GtkObject *object,
- const gchar *name,
- GtkSignalFunc func,
- gpointer func_data)
-{
- guint signal_id;
-
- g_return_val_if_fail (object != NULL, 0);
-
- signal_id = gtk_signal_lookup (name, GTK_OBJECT_TYPE (object));
- if (!signal_id)
- {
- g_warning ("gtk_signal_connect_after(): could not find signal \"%s\" in the `%s' class ancestry",
- name,
- gtk_type_name (GTK_OBJECT_TYPE (object)));
- return 0;
- }
-
- return gtk_signal_connect_by_type (object, signal_id,
- func, func_data, NULL,
- FALSE, TRUE, FALSE);
-}
-
-guint
-gtk_signal_connect_full (GtkObject *object,
- const gchar *name,
- GtkSignalFunc func,
- GtkCallbackMarshal marshal,
- gpointer func_data,
+gtk_signal_connect_full (GtkObject *object,
+ const gchar *name,
+ GtkSignalFunc func,
+ GtkCallbackMarshal unsupported,
+ gpointer data,
GtkDestroyNotify destroy_func,
- gint object_signal,
- gint after)
+ gint object_signal,
+ gint after)
{
- guint signal_id;
-
- g_return_val_if_fail (object != NULL, 0);
-
- signal_id = gtk_signal_lookup (name, GTK_OBJECT_TYPE (object));
- if (!signal_id)
- {
- g_warning ("gtk_signal_connect_full(): could not find signal \"%s\" in the `%s' class ancestry",
- name,
- gtk_type_name (GTK_OBJECT_TYPE (object)));
- return 0;
- }
-
- if (marshal)
- return gtk_signal_connect_by_type (object, signal_id, (GtkSignalFunc) marshal,
- func_data, destroy_func,
- object_signal, after, TRUE);
- else
- return gtk_signal_connect_by_type (object, signal_id, func,
- func_data, destroy_func,
- object_signal, after, FALSE);
-}
-
-guint
-gtk_signal_connect_object (GtkObject *object,
- const gchar *name,
- GtkSignalFunc func,
- GtkObject *slot_object)
-{
- guint signal_id;
-
- g_return_val_if_fail (object != NULL, 0);
- /* slot_object needs to be treated as ordinary pointer
- */
-
- signal_id = gtk_signal_lookup (name, GTK_OBJECT_TYPE (object));
- if (!signal_id)
- {
- g_warning ("gtk_signal_connect_object(): could not find signal \"%s\" in the `%s' class ancestry",
- name,
- gtk_type_name (GTK_OBJECT_TYPE (object)));
- return 0;
- }
-
- return gtk_signal_connect_by_type (object, signal_id,
- func, slot_object, NULL,
- TRUE, FALSE, FALSE);
-}
-
-guint
-gtk_signal_connect_object_after (GtkObject *object,
- const gchar *name,
- GtkSignalFunc func,
- GtkObject *slot_object)
-{
- guint signal_id;
-
- g_return_val_if_fail (object != NULL, 0);
-
- signal_id = gtk_signal_lookup (name, GTK_OBJECT_TYPE (object));
- if (!signal_id)
- {
- g_warning ("gtk_signal_connect_object_after(): could not find signal \"%s\" in the `%s' class ancestry",
- name,
- gtk_type_name (GTK_OBJECT_TYPE (object)));
- return 0;
- }
-
- return gtk_signal_connect_by_type (object, signal_id,
- func, slot_object, NULL,
- TRUE, TRUE, FALSE);
-}
-
-void
-gtk_signal_connect_while_alive (GtkObject *object,
- const gchar *signal,
- GtkSignalFunc func,
- gpointer func_data,
- GtkObject *alive_object)
-{
- GtkDisconnectInfo *info;
-
- g_return_if_fail (object != NULL);
- g_return_if_fail (GTK_IS_OBJECT (object));
- g_return_if_fail (signal != NULL);
- g_return_if_fail (func != NULL);
- g_return_if_fail (alive_object != NULL);
- g_return_if_fail (GTK_IS_OBJECT (alive_object));
-
- info = g_chunk_new (GtkDisconnectInfo, gtk_disconnect_info_mem_chunk);
- info->object1 = object;
- info->object2 = alive_object;
+ g_return_val_if_fail (GTK_IS_OBJECT (object), 0);
+ g_return_val_if_fail (unsupported == NULL, 0);
- info->signal_handler = gtk_signal_connect (object, signal, func, func_data);
- info->disconnect_handler1 =
- gtk_signal_connect_object (info->object1,
- "destroy",
- GTK_SIGNAL_FUNC (gtk_alive_disconnecter),
- (GtkObject*) info);
- info->disconnect_handler2 =
- gtk_signal_connect_object (info->object2,
- "destroy",
- GTK_SIGNAL_FUNC (gtk_alive_disconnecter),
- (GtkObject*) info);
+ return g_signal_connect_closure (object,
+ g_signal_lookup (name, G_OBJECT_TYPE (object)),
+ (object_signal
+ ? g_cclosure_new_swap
+ : g_cclosure_new) (func,
+ data,
+ (GClosureNotify) destroy_func),
+ after);
}
void
-gtk_signal_connect_object_while_alive (GtkObject *object,
- const gchar *signal,
- GtkSignalFunc func,
- GtkObject *alive_object)
+gtk_signal_compat_matched (GtkObject *object,
+ GtkSignalFunc func,
+ gpointer data,
+ GSignalMatchType match,
+ guint action)
{
- GtkDisconnectInfo *info;
+ guint id;
- g_return_if_fail (object != NULL);
g_return_if_fail (GTK_IS_OBJECT (object));
- g_return_if_fail (signal != NULL);
- g_return_if_fail (func != NULL);
- g_return_if_fail (alive_object != NULL);
- g_return_if_fail (GTK_IS_OBJECT (alive_object));
-
- info = g_chunk_new (GtkDisconnectInfo, gtk_disconnect_info_mem_chunk);
- info->object1 = object;
- info->object2 = alive_object;
-
- info->signal_handler = gtk_signal_connect_object (object, signal, func, alive_object);
- info->disconnect_handler1 =
- gtk_signal_connect_object (info->object1,
- "destroy",
- GTK_SIGNAL_FUNC (gtk_alive_disconnecter),
- (GtkObject*) info);
- info->disconnect_handler2 =
- gtk_signal_connect_object (info->object2,
- "destroy",
- GTK_SIGNAL_FUNC (gtk_alive_disconnecter),
- (GtkObject*) info);
-}
-
-void
-gtk_signal_disconnect (GtkObject *object,
- guint handler_id)
-{
- GtkHandler *handler;
-
- g_return_if_fail (object != NULL);
- g_return_if_fail (handler_id > 0);
- handler = gtk_object_get_data_by_id (object, gtk_handler_quark);
+ id = g_signal_handler_find (object, match, 0, NULL, func, data);
- while (handler)
- {
- if (handler->id == handler_id)
- {
- handler->id = 0;
- handler->blocked += 1;
- gtk_signal_handler_unref (handler, object);
- return;
- }
- handler = handler->next;
- }
-
- g_warning ("gtk_signal_disconnect(): could not find handler (%u)", handler_id);
+ if (!id)
+ g_warning ("unable to find signal handler for object(%p) with func(%p) and data(%p)",
+ object, func, data);
+ else
+ switch (action)
+ {
+ case 0: g_signal_handler_disconnect (object, id); break;
+ case 1: g_signal_handler_block (object, id); break;
+ case 2: g_signal_handler_unblock (object, id); break;
+ }
}
-void
-gtk_signal_disconnect_by_func (GtkObject *object,
- GtkSignalFunc func,
- gpointer data)
-{
- GtkHandler *handler;
- gint found_one;
-
- g_return_if_fail (object != NULL);
- g_return_if_fail (func != NULL);
-
- found_one = FALSE;
- handler = gtk_object_get_data_by_id (object, gtk_handler_quark);
-
- while (handler)
- {
- GtkHandler *handler_next;
-
- handler_next = handler->next;
- if ((handler->id > 0) &&
- (handler->func == func) &&
- (handler->func_data == data))
- {
- found_one = TRUE;
- handler->id = 0;
- handler->blocked += 1;
- gtk_signal_handler_unref (handler, object);
- }
- handler = handler_next;
- }
-
- if (!found_one)
- g_warning ("gtk_signal_disconnect_by_func(): could not find handler (0x%0lX) containing data (0x%0lX)", (long) func, (long) data);
+static inline gboolean
+gtk_arg_to_value (GtkArg *arg,
+ GValue *value)
+{
+ switch (G_TYPE_FUNDAMENTAL (arg->type))
+ {
+ case G_TYPE_CHAR: g_value_set_char (value, GTK_VALUE_CHAR (*arg)); break;
+ case G_TYPE_UCHAR: g_value_set_uchar (value, GTK_VALUE_UCHAR (*arg)); break;
+ case G_TYPE_BOOLEAN: g_value_set_boolean (value, GTK_VALUE_BOOL (*arg)); break;
+ case G_TYPE_INT: g_value_set_int (value, GTK_VALUE_INT (*arg)); break;
+ case G_TYPE_UINT: g_value_set_uint (value, GTK_VALUE_UINT (*arg)); break;
+ case G_TYPE_LONG: g_value_set_long (value, GTK_VALUE_LONG (*arg)); break;
+ case G_TYPE_ULONG: g_value_set_ulong (value, GTK_VALUE_ULONG (*arg)); break;
+ case G_TYPE_ENUM: g_value_set_enum (value, GTK_VALUE_ENUM (*arg)); break;
+ case G_TYPE_FLAGS: g_value_set_flags (value, GTK_VALUE_FLAGS (*arg)); break;
+ case G_TYPE_FLOAT: g_value_set_float (value, GTK_VALUE_FLOAT (*arg)); break;
+ case G_TYPE_DOUBLE: g_value_set_double (value, GTK_VALUE_DOUBLE (*arg)); break;
+ case G_TYPE_STRING: g_value_set_string (value, GTK_VALUE_STRING (*arg)); break;
+ case G_TYPE_BOXED: g_value_set_boxed (value, GTK_VALUE_BOXED (*arg)); break;
+ case G_TYPE_POINTER: g_value_set_pointer (value, GTK_VALUE_POINTER (*arg)); break;
+ case G_TYPE_OBJECT: g_value_set_object (value, GTK_VALUE_POINTER (*arg)); break;
+ default:
+ return FALSE;
+ }
+ return TRUE;
+}
+
+static inline gboolean
+gtk_arg_set_from_value (GtkArg *arg,
+ GValue *value,
+ gboolean copy_string)
+{
+ switch (G_TYPE_FUNDAMENTAL (arg->type))
+ {
+ case G_TYPE_CHAR: GTK_VALUE_CHAR (*arg) = g_value_get_char (value); break;
+ case G_TYPE_UCHAR: GTK_VALUE_UCHAR (*arg) = g_value_get_uchar (value); break;
+ case G_TYPE_BOOLEAN: GTK_VALUE_BOOL (*arg) = g_value_get_boolean (value); break;
+ case G_TYPE_INT: GTK_VALUE_INT (*arg) = g_value_get_int (value); break;
+ case G_TYPE_UINT: GTK_VALUE_UINT (*arg) = g_value_get_uint (value); break;
+ case G_TYPE_LONG: GTK_VALUE_LONG (*arg) = g_value_get_long (value); break;
+ case G_TYPE_ULONG: GTK_VALUE_ULONG (*arg) = g_value_get_ulong (value); break;
+ case G_TYPE_ENUM: GTK_VALUE_ENUM (*arg) = g_value_get_enum (value); break;
+ case G_TYPE_FLAGS: GTK_VALUE_FLAGS (*arg) = g_value_get_flags (value); break;
+ case G_TYPE_FLOAT: GTK_VALUE_FLOAT (*arg) = g_value_get_float (value); break;
+ case G_TYPE_DOUBLE: GTK_VALUE_DOUBLE (*arg) = g_value_get_double (value); break;
+ case G_TYPE_BOXED: GTK_VALUE_BOXED (*arg) = g_value_get_boxed (value); break;
+ case G_TYPE_POINTER: GTK_VALUE_POINTER (*arg) = g_value_get_pointer (value); break;
+ case G_TYPE_OBJECT: GTK_VALUE_POINTER (*arg) = g_value_get_object (value); break;
+ case G_TYPE_STRING: if (copy_string)
+ GTK_VALUE_STRING (*arg) = g_value_dup_string (value);
+ else
+ GTK_VALUE_STRING (*arg) = g_value_get_string (value);
+ break;
+ default:
+ return FALSE;
+ }
+ return TRUE;
+}
+
+static inline gboolean
+gtk_argloc_set_from_value (GtkArg *arg,
+ GValue *value,
+ gboolean copy_string)
+{
+ switch (G_TYPE_FUNDAMENTAL (arg->type))
+ {
+ case G_TYPE_CHAR: *GTK_RETLOC_CHAR (*arg) = g_value_get_char (value); break;
+ case G_TYPE_UCHAR: *GTK_RETLOC_UCHAR (*arg) = g_value_get_uchar (value); break;
+ case G_TYPE_BOOLEAN: *GTK_RETLOC_BOOL (*arg) = g_value_get_boolean (value); break;
+ case G_TYPE_INT: *GTK_RETLOC_INT (*arg) = g_value_get_int (value); break;
+ case G_TYPE_UINT: *GTK_RETLOC_UINT (*arg) = g_value_get_uint (value); break;
+ case G_TYPE_LONG: *GTK_RETLOC_LONG (*arg) = g_value_get_long (value); break;
+ case G_TYPE_ULONG: *GTK_RETLOC_ULONG (*arg) = g_value_get_ulong (value); break;
+ case G_TYPE_ENUM: *GTK_RETLOC_ENUM (*arg) = g_value_get_enum (value); break;
+ case G_TYPE_FLAGS: *GTK_RETLOC_FLAGS (*arg) = g_value_get_flags (value); break;
+ case G_TYPE_FLOAT: *GTK_RETLOC_FLOAT (*arg) = g_value_get_float (value); break;
+ case G_TYPE_DOUBLE: *GTK_RETLOC_DOUBLE (*arg) = g_value_get_double (value); break;
+ case G_TYPE_BOXED: *GTK_RETLOC_BOXED (*arg) = g_value_get_boxed (value); break;
+ case G_TYPE_POINTER: *GTK_RETLOC_POINTER (*arg) = g_value_get_pointer (value); break;
+ case G_TYPE_OBJECT: *GTK_RETLOC_POINTER (*arg) = g_value_get_object (value); break;
+ case G_TYPE_STRING: if (copy_string)
+ *GTK_RETLOC_STRING (*arg) = g_value_dup_string (value);
+ else
+ *GTK_RETLOC_STRING (*arg) = g_value_get_string (value);
+ break;
+ default:
+ return FALSE;
+ }
+ return TRUE;
}
void
-gtk_signal_disconnect_by_data (GtkObject *object,
- gpointer data)
+gtk_signal_emitv (GtkObject *object,
+ guint signal_id,
+ GtkArg *args)
{
- GtkHandler *handler;
- gint found_one;
+ GSignalQuery query;
+ GValue params[SIGNAL_MAX_PARAMS + 1] = { { 0, }, };
+ GValue rvalue = { 0, };
+ guint i;
- g_return_if_fail (object != NULL);
+ g_return_if_fail (GTK_IS_OBJECT (object));
- found_one = FALSE;
- handler = gtk_object_get_data_by_id (object, gtk_handler_quark);
+ g_signal_query (signal_id, &query);
+ g_return_if_fail (query.signal_id != 0);
+ g_return_if_fail (g_type_conforms_to (GTK_OBJECT_TYPE (object), query.itype));
+ g_return_if_fail (query.n_params < SIGNAL_MAX_PARAMS);
+ if (query.n_params > 0)
+ g_return_if_fail (args != NULL);
- while (handler)
+ g_value_init (params + 0, GTK_OBJECT_TYPE (object));
+ g_value_set_object (params + 0, G_OBJECT (object));
+ for (i = 0; i < query.n_params; i++)
{
- GtkHandler *handler_next;
+ GValue *value = params + 1 + i;
+ GtkArg *arg = args + i;
- handler_next = handler->next;
- if ((handler->id > 0) &&
- (handler->func_data == data))
+ g_value_init (value, arg->type);
+ if (!gtk_arg_to_value (arg, value))
{
- found_one = TRUE;
- handler->id = 0;
- handler->blocked += 1;
- gtk_signal_handler_unref (handler, object);
- }
- handler = handler_next;
- }
-
- if (!found_one)
- g_warning ("gtk_signal_disconnect_by_data(): could not find handler containing data (0x%0lX)", (long) data);
-}
-
-void
-gtk_signal_handler_block (GtkObject *object,
- guint handler_id)
-{
- GtkHandler *handler;
-
- g_return_if_fail (object != NULL);
- g_return_if_fail (handler_id > 0);
-
- handler = gtk_object_get_data_by_id (object, gtk_handler_quark);
-
- while (handler)
- {
- if (handler->id == handler_id)
- {
- handler->blocked += 1;
+ g_warning ("%s: failed to convert arg type `%s' to value type `%s'",
+ G_STRLOC, g_type_name (arg->type), g_type_name (G_VALUE_TYPE (value)));
return;
}
- handler = handler->next;
}
+ if (query.return_type != G_TYPE_NONE)
+ g_value_init (&rvalue, query.return_type);
- g_warning ("gtk_signal_handler_block(): could not find handler (%u)", handler_id);
-}
-
-void
-gtk_signal_handler_block_by_func (GtkObject *object,
- GtkSignalFunc func,
- gpointer data)
-{
- GtkHandler *handler;
- gint found_one;
-
- g_return_if_fail (object != NULL);
- g_return_if_fail (func != NULL);
-
- found_one = FALSE;
- handler = gtk_object_get_data_by_id (object, gtk_handler_quark);
+ g_signal_emitv (params, signal_id, &rvalue);
- while (handler)
+ if (query.return_type != G_TYPE_NONE)
{
- if ((handler->id > 0) &&
- (handler->func == func) &&
- (handler->func_data == data))
- {
- found_one = TRUE;
- handler->blocked += 1;
- }
- handler = handler->next;
+ gtk_argloc_set_from_value (args + query.n_params, &rvalue, TRUE);
+ g_value_unset (&rvalue);
}
-
- if (!found_one)
- g_warning ("gtk_signal_handler_block_by_func(): could not find handler (0x%0lX) containing data (0x%0lX)", (long) func, (long) data);
+ for (i = 0; i < query.n_params; i++)
+ g_value_unset (params + 1 + i);
+ g_value_unset (params + 0);
}
-void
-gtk_signal_handler_block_by_data (GtkObject *object,
- gpointer data)
-{
- GtkHandler *handler;
- gint found_one;
-
- g_return_if_fail (object != NULL);
-
- found_one = FALSE;
- handler = gtk_object_get_data_by_id (object, gtk_handler_quark);
-
- while (handler)
- {
- if ((handler->id > 0) &&
- (handler->func_data == data))
- {
- found_one = TRUE;
- handler->blocked += 1;
- }
- handler = handler->next;
- }
-
- if (!found_one)
- g_warning ("gtk_signal_handler_block_by_data(): could not find handler containing data (0x%0lX)", (long) data);
-}
-
-void
-gtk_signal_handler_unblock (GtkObject *object,
- guint handler_id)
-{
- GtkHandler *handler;
-
- g_return_if_fail (object != NULL);
- g_return_if_fail (handler_id > 0);
-
- handler = gtk_object_get_data_by_id (object, gtk_handler_quark);
-
- while (handler)
- {
- if (handler->id == handler_id)
- {
- if (handler->blocked > 0)
- handler->blocked -= 1;
- else
- g_warning ("gtk_signal_handler_unblock(): handler (%u) is not blocked", handler_id);
- return;
- }
- handler = handler->next;
- }
-
- g_warning ("gtk_signal_handler_unblock(): could not find handler (%u)", handler_id);
-}
-
-void
-gtk_signal_handler_unblock_by_func (GtkObject *object,
- GtkSignalFunc func,
- gpointer data)
-{
- GtkHandler *handler;
- gint found_one;
-
- g_return_if_fail (object != NULL);
- g_return_if_fail (func != NULL);
-
- found_one = FALSE;
- handler = gtk_object_get_data_by_id (object, gtk_handler_quark);
-
- while (handler)
- {
- if ((handler->id > 0) &&
- (handler->func == func) &&
- (handler->func_data == data) &&
- (handler->blocked > 0))
- {
- handler->blocked -= 1;
- found_one = TRUE;
- }
- handler = handler->next;
- }
-
- if (!found_one)
- g_warning ("gtk_signal_handler_unblock_by_func(): could not find blocked handler (0x%0lX) containing data (0x%0lX)", (long) func, (long) data);
-}
-
-void
-gtk_signal_handler_unblock_by_data (GtkObject *object,
- gpointer data)
-{
- GtkHandler *handler;
- gint found_one;
-
- g_return_if_fail (object != NULL);
-
- found_one = FALSE;
- handler = gtk_object_get_data_by_id (object, gtk_handler_quark);
-
- while (handler)
- {
- if ((handler->id > 0) &&
- (handler->func_data == data) &&
- (handler->blocked > 0))
- {
- handler->blocked -= 1;
- found_one = TRUE;
- }
- handler = handler->next;
- }
-
- if (!found_one)
- g_warning ("gtk_signal_handler_unblock_by_data(): could not find blocked handler containing data (0x%0lX)", (long) data);
-}
-
-void
-gtk_signal_handlers_destroy (GtkObject *object)
-{
- GtkHandler *handler;
-
- /* we make the "optimization" of destroying the first handler in the last
- * place, since we don't want gtk_signal_handler_unref() to reset the objects
- * handler_key data on each removal
- */
-
- handler = gtk_object_get_data_by_id (object, gtk_handler_quark);
- if (handler)
- {
- handler = handler->next;
- while (handler)
- {
- GtkHandler *next;
-
- next = handler->next;
- if (handler->id > 0)
- {
- handler->id = 0;
- handler->blocked += 1;
- gtk_signal_handler_unref (handler, object);
- }
- handler = next;
- }
- handler = gtk_object_get_data_by_id (object, gtk_handler_quark);
- if (handler->id > 0)
- {
- handler->id = 0;
- handler->blocked += 1;
- gtk_signal_handler_unref (handler, object);
- }
- }
-}
-
-void
-gtk_signal_set_funcs (GtkSignalMarshal marshal_func,
- GtkSignalDestroy destroy_func)
-{
- global_marshaller = marshal_func;
- global_destroy_notify = destroy_func;
-}
-
-static guint
-gtk_signal_hash (gconstpointer h)
-{
- register const GtkSignalHash *hash = h;
-
- return hash->object_type ^ hash->quark;
-}
-
-static gint
-gtk_signal_compare (gconstpointer h1,
- gconstpointer h2)
-{
- register const GtkSignalHash *hash1 = h1;
- register const GtkSignalHash *hash2 = h2;
-
- return (hash1->quark == hash2->quark &&
- hash1->object_type == hash2->object_type);
-}
-
-static guint
-gtk_alive_disconnecter (GtkDisconnectInfo *info)
-{
- g_return_val_if_fail (info != NULL, 0);
-
- gtk_signal_disconnect (info->object1, info->disconnect_handler1);
- gtk_signal_disconnect (info->object1, info->signal_handler);
- gtk_signal_disconnect (info->object2, info->disconnect_handler2);
-
- g_mem_chunk_free (gtk_disconnect_info_mem_chunk, info);
-
- return 0;
-}
-
-static GtkHandler*
-gtk_signal_handler_new (void)
-{
- GtkHandler *handler;
-
- if (!gtk_handler_free_list)
- {
- GtkHandler *handler_block;
- guint i;
-
- handler_block = g_new0 (GtkHandler, HANDLER_BLOCK_SIZE);
- for (i = 1; i < HANDLER_BLOCK_SIZE; i++)
- {
- (handler_block + i)->next = gtk_handler_free_list;
- gtk_handler_free_list = (handler_block + i);
- }
-
- handler = handler_block;
- }
- else
- {
- handler = gtk_handler_free_list;
- gtk_handler_free_list = handler->next;
- }
-
- handler->id = 0;
- handler->blocked = 0;
- handler->signal_id = 0;
- handler->object_signal = FALSE;
- handler->after = FALSE;
- handler->no_marshal = FALSE;
- handler->ref_count = 1;
- handler->func = NULL;
- handler->func_data = NULL;
- handler->destroy_func = NULL;
- handler->prev = NULL;
- handler->next = NULL;
-
- return handler;
-}
-
-static void
-gtk_signal_handler_ref (GtkHandler *handler)
-{
- handler->ref_count += 1;
-}
-
-static void
-gtk_signal_handler_unref (GtkHandler *handler,
- GtkObject *object)
-{
- if (!handler->ref_count)
- {
- /* FIXME: i wanna get removed somewhen */
- g_warning ("gtk_signal_handler_unref(): handler with ref_count==0!");
- return;
- }
-
- handler->ref_count -= 1;
-
- if (handler->ref_count == 0)
- {
- if (handler->destroy_func)
- (* handler->destroy_func) (handler->func_data);
- else if (!handler->func && global_destroy_notify)
- (* global_destroy_notify) (handler->func_data);
-
- if (handler->prev)
- handler->prev->next = handler->next;
- else if (handler->next)
- gtk_object_set_data_by_id (object, gtk_handler_quark, handler->next);
- else
- {
- GTK_OBJECT_UNSET_FLAGS (object, GTK_CONNECTED);
- gtk_object_set_data_by_id (object, gtk_handler_quark, NULL);
- }
- if (handler->next)
- handler->next->prev = handler->prev;
-
- handler->next = gtk_handler_free_list;
- gtk_handler_free_list = handler;
- }
-}
-
-static void
-gtk_signal_handler_insert (GtkObject *object,
- GtkHandler *handler)
-{
- GtkHandler *tmp;
-
- /* FIXME: remove */ g_assert (handler->next == NULL);
- /* FIXME: remove */ g_assert (handler->prev == NULL);
-
- tmp = gtk_object_get_data_by_id (object, gtk_handler_quark);
- if (!tmp)
- {
- GTK_OBJECT_SET_FLAGS (object, GTK_CONNECTED);
- gtk_object_set_data_by_id (object, gtk_handler_quark, handler);
- }
- else
- while (tmp)
- {
- if (tmp->signal_id < handler->signal_id)
- {
- if (tmp->prev)
- {
- tmp->prev->next = handler;
- handler->prev = tmp->prev;
- }
- else
- gtk_object_set_data_by_id (object, gtk_handler_quark, handler);
- tmp->prev = handler;
- handler->next = tmp;
- break;
- }
-
- if (!tmp->next)
- {
- tmp->next = handler;
- handler->prev = tmp;
- break;
- }
- tmp = tmp->next;
- }
-}
-
-
-#ifdef G_ENABLE_DEBUG
-/* value typically set via gdb */
-static GtkObject *gtk_trace_signal_object = NULL;
-#endif /* G_ENABLE_DEBUG */
-
-
-static void
-gtk_signal_real_emit (GtkObject *object,
- guint signal_id,
- GtkArg *params)
+static gboolean
+gtk_signal_collect_args (GtkArg *args,
+ guint n_args,
+ const GtkType *arg_types,
+ GtkType return_type,
+ va_list var_args)
{
- GtkSignal signal;
- GtkHandler *handlers;
- GtkSignalFunc signal_func;
- GtkEmission *emission;
-
- /* gtk_handlers_run() expects a reentrant GtkSignal*, so we allocate
- * it locally on the stack. we save some lookups ourselves with this as well.
- */
- signal = *LOOKUP_SIGNAL_ID (signal_id);
- if (signal.function_offset)
- signal_func = G_STRUCT_MEMBER (GtkSignalFunc, ((GTypeInstance*) object)->g_class, signal.function_offset);
- else
- signal_func = NULL;
-
-#ifdef G_ENABLE_DEBUG
- if (gtk_debug_flags & GTK_DEBUG_SIGNALS ||
- object == gtk_trace_signal_object)
- g_message ("%s::%s emitted (object=%p class-method=%p)\n",
- gtk_type_name (GTK_OBJECT_TYPE (object)),
- signal.name,
- object,
- signal_func);
-#endif /* G_ENABLE_DEBUG */
-
- if (signal.signal_flags & GTK_RUN_NO_RECURSE)
- {
- gint state;
-
- state = gtk_emission_check (current_emissions, object, signal_id);
- if (state)
- {
- if (state > 1)
- g_warning ("gtk_signal_real_emit(): emission (%u) for object `%s' cannot be restarted from emission hook",
- signal_id,
- gtk_type_name (GTK_OBJECT_TYPE (object)));
- else if (!gtk_emission_check (restart_emissions, object, signal_id))
- gtk_emission_add (&restart_emissions, object, signal_id);
-
- return;
- }
- }
-
- gtk_object_ref (object);
-
- gtk_emission_add (&current_emissions, object, signal_id);
- emission = current_emissions;
-
- emission_restart:
+ register GtkArg *last_arg;
+ register gboolean failed = FALSE;
- if (signal.signal_flags & GTK_RUN_FIRST && signal_func)
+ for (last_arg = args + n_args; args < last_arg; args++)
{
- signal.marshaller (object, signal_func, NULL, params);
+ register gchar *error;
- if (stop_emissions && gtk_emission_check (stop_emissions, object, signal_id))
- {
- gtk_emission_remove (&stop_emissions, object, signal_id);
- goto emission_done;
- }
- else if (restart_emissions &&
- signal.signal_flags & GTK_RUN_NO_RECURSE &&
- gtk_emission_check (restart_emissions, object, signal_id))
+ args->name = NULL;
+ args->type = *(arg_types++);
+ GTK_ARG_COLLECT_VALUE (args,
+ var_args,
+ error);
+ if (error)
{
- gtk_emission_remove (&restart_emissions, object, signal_id);
-
- goto emission_restart;
+ failed = TRUE;
+ g_warning ("gtk_signal_collect_args(): %s", error);
+ g_free (error);
}
}
- if (signal.hook_list && !GTK_OBJECT_DESTROYED (object))
- {
- GtkEmissionHookData data;
-
- data.object = object;
- data.n_params = signal.nparams;
- data.params = params;
- data.signal_id = signal_id;
- emission->in_hook = 1;
- g_hook_list_marshal_check (signal.hook_list, TRUE, gtk_emission_hook_marshaller, &data);
- emission->in_hook = 0;
- }
-
- if (GTK_OBJECT_CONNECTED (object))
- {
- handlers = gtk_signal_get_handlers (object, signal_id);
- if (handlers)
- {
- gint return_val;
-
- return_val = gtk_handlers_run (handlers, &signal, object, params, FALSE);
- switch (return_val)
- {
- case EMISSION_CONTINUE:
- break;
- case EMISSION_RESTART:
- goto emission_restart;
- case EMISSION_DONE:
- goto emission_done;
- }
- }
- }
+ args->type = return_type;
+ args->name = NULL;
- if (signal.signal_flags & GTK_RUN_LAST && signal_func)
- {
- signal.marshaller (object, signal_func, NULL, params);
-
- if (stop_emissions && gtk_emission_check (stop_emissions, object, signal_id))
- {
- gtk_emission_remove (&stop_emissions, object, signal_id);
- goto emission_done;
- }
- else if (restart_emissions &&
- signal.signal_flags & GTK_RUN_NO_RECURSE &&
- gtk_emission_check (restart_emissions, object, signal_id))
- {
- gtk_emission_remove (&restart_emissions, object, signal_id);
-
- goto emission_restart;
- }
- }
-
- if (GTK_OBJECT_CONNECTED (object))
+ return_type = GTK_FUNDAMENTAL_TYPE (return_type);
+ if (return_type != G_TYPE_NONE)
{
- handlers = gtk_signal_get_handlers (object, signal_id);
- if (handlers)
+ if (return_type != 0) /* FIXME: check for IS_ARG */
{
- gint return_val;
+ GTK_VALUE_POINTER (*args) = va_arg (var_args, gpointer);
- return_val = gtk_handlers_run (handlers, &signal, object, params, TRUE);
- switch (return_val)
+ if (GTK_VALUE_POINTER (*args) == NULL)
{
- case EMISSION_CONTINUE:
- break;
- case EMISSION_RESTART:
- goto emission_restart;
- case EMISSION_DONE:
- goto emission_done;
+ failed = TRUE;
+ g_warning ("gtk_signal_collect_args(): invalid NULL pointer for return argument type `%s'",
+ gtk_type_name (args->type));
}
}
- }
-
- emission_done:
- if (restart_emissions && signal.signal_flags & GTK_RUN_NO_RECURSE)
- gtk_emission_remove (&restart_emissions, object, signal_id);
-
- gtk_emission_remove (&current_emissions, object, signal_id);
-
- gtk_object_unref (object);
-}
-
-guint
-gtk_signal_handler_pending (GtkObject *object,
- guint signal_id,
- gboolean may_be_blocked)
-{
- GtkHandler *handlers;
- guint handler_id;
-
- g_return_val_if_fail (object != NULL, 0);
- g_return_val_if_fail (signal_id >= 1, 0);
-
- if (GTK_OBJECT_CONNECTED (object))
- handlers = gtk_signal_get_handlers (object, signal_id);
- else
- return 0;
-
- handler_id = 0;
- while (handlers && handlers->signal_id == signal_id)
- {
- if (handlers->id > 0 &&
- (may_be_blocked || handlers->blocked == FALSE))
- {
- handler_id = handlers->id;
- break;
- }
-
- handlers = handlers->next;
- }
-
- return handler_id;
-}
-
-guint
-gtk_signal_handler_pending_by_func (GtkObject *object,
- guint signal_id,
- gboolean may_be_blocked,
- GtkSignalFunc func,
- gpointer data)
-{
- GtkHandler *handlers;
- guint handler_id;
-
- g_return_val_if_fail (object != NULL, 0);
- g_return_val_if_fail (func != NULL, 0);
- g_return_val_if_fail (signal_id >= 1, 0);
-
- if (GTK_OBJECT_CONNECTED (object))
- handlers = gtk_signal_get_handlers (object, signal_id);
- else
- return 0;
-
- handler_id = 0;
- while (handlers && handlers->signal_id == signal_id)
- {
- if (handlers->id > 0 &&
- handlers->func == func &&
- handlers->func_data == data &&
- (may_be_blocked || handlers->blocked == 0))
+ else
{
- handler_id = handlers->id;
- break;
+ failed = TRUE;
+ g_warning ("gtk_signal_collect_args(): unsupported return argument type `%s'",
+ gtk_type_name (args->type));
}
-
- handlers = handlers->next;
}
-
- return handler_id;
-}
-
-gint
-gtk_signal_handler_pending_by_id (GtkObject *object,
- guint handler_id,
- gboolean may_be_blocked)
-{
- GtkHandler *handlers;
-
- g_return_val_if_fail (object != NULL, FALSE);
- g_return_val_if_fail (handler_id >= 1, FALSE);
-
- if (GTK_OBJECT_CONNECTED (object))
- handlers = gtk_object_get_data_by_id (object, gtk_handler_quark);
else
- return FALSE;
+ GTK_VALUE_POINTER (*args) = NULL;
- while (handlers)
- {
- if (handlers->id == handler_id)
- return may_be_blocked || handlers->blocked == 0;
-
- handlers = handlers->next;
- }
-
- return FALSE;
-}
-
-guint
-gtk_signal_add_emission_hook (guint signal_id,
- GtkEmissionHook hook_func,
- gpointer data)
-{
- return gtk_signal_add_emission_hook_full (signal_id, hook_func, data, NULL);
-}
-
-guint
-gtk_signal_add_emission_hook_full (guint signal_id,
- GtkEmissionHook hook_func,
- gpointer data,
- GDestroyNotify destroy)
-{
- static guint seq_hook_id = 1;
- GtkSignal *signal;
- GHook *hook;
-
- g_return_val_if_fail (signal_id > 0, 0);
- g_return_val_if_fail (hook_func != NULL, 0);
-
- signal = LOOKUP_SIGNAL_ID (signal_id);
- g_return_val_if_fail (signal != NULL, 0);
- if (signal->signal_flags & GTK_RUN_NO_HOOKS)
- {
- g_warning ("gtk_signal_add_emission_hook_full(): signal \"%s\" does not support emission hooks",
- signal->name);
- return 0;
- }
-
- if (!signal->hook_list)
- {
- signal->hook_list = g_new (GHookList, 1);
- g_hook_list_init (signal->hook_list, sizeof (GHook));
- }
-
- hook = g_hook_alloc (signal->hook_list);
- hook->data = data;
- hook->func = hook_func;
- hook->destroy = destroy;
-
- signal->hook_list->seq_id = seq_hook_id;
- g_hook_prepend (signal->hook_list, hook);
- seq_hook_id = signal->hook_list->seq_id;
-
- return hook->hook_id;
+ return failed;
}
void
-gtk_signal_remove_emission_hook (guint signal_id,
- guint hook_id)
-{
- GtkSignal *signal;
-
- g_return_if_fail (signal_id > 0);
- g_return_if_fail (hook_id > 0);
-
- signal = LOOKUP_SIGNAL_ID (signal_id);
- g_return_if_fail (signal != NULL);
-
- if (!signal->hook_list || !g_hook_destroy (signal->hook_list, hook_id))
- g_warning ("gtk_signal_remove_emission_hook(): could not find hook (%u)", hook_id);
-}
-
-static gboolean
-gtk_emission_hook_marshaller (GHook *hook,
- gpointer data_p)
-{
- GtkEmissionHookData *data = data_p;
- GtkEmissionHook func;
-
- func = hook->func;
-
- if (!GTK_OBJECT_DESTROYED (data->object))
- return func (data->object, data->signal_id,
- data->n_params, data->params,
- hook->data);
- else
- return TRUE;
-}
-
-static guint
-gtk_signal_connect_by_type (GtkObject *object,
- guint signal_id,
- GtkSignalFunc func,
- gpointer func_data,
- GtkSignalDestroy destroy_func,
- gint object_signal,
- gint after,
- gint no_marshal)
+gtk_signal_emit (GtkObject *object,
+ guint signal_id,
+ ...)
{
- GtkObjectClass *class;
- GtkHandler *handler;
- gint found_it;
- GtkSignal *signal;
-
- g_return_val_if_fail (GTK_IS_OBJECT (object), 0);
+ GtkArg args[SIGNAL_MAX_PARAMS + 1];
+ GSignalQuery query;
+ gboolean abort;
+ va_list var_args;
- signal = LOOKUP_SIGNAL_ID (signal_id);
-
- /* Search through the signals for this object and make
- * sure the one we are adding is valid. We need to perform
- * the lookup on the objects parents as well. If it isn't
- * valid then issue a warning and return.
- * As of now (1998-05-27) this lookup shouldn't be neccessarry
- * anymore since gtk_signal_lookup() has been reworked to only
- * return correct signal ids per class-branch.
- */
- found_it = FALSE;
- class = GTK_OBJECT_GET_CLASS (object);
- while (class)
- {
- GtkType parent;
- guint *object_signals;
- guint nsignals;
- guint i;
-
- object_signals = class->signals;
- nsignals = class->nsignals;
-
- for (i = 0; i < nsignals; i++)
- if (object_signals[i] == signal_id)
- {
- found_it = TRUE;
- break;
- }
-
- parent = g_type_parent (GTK_CLASS_TYPE (class));
- if (GTK_TYPE_IS_OBJECT (parent))
- class = g_type_class_peek (parent);
- else
- class = NULL;
- }
+ g_return_if_fail (GTK_IS_OBJECT (object));
- if (!found_it)
- {
- g_warning ("gtk_signal_connect_by_type(): could not find signal id (%u) in the `%s' class ancestry",
- signal_id,
- GTK_OBJECT_TYPE_NAME (object));
- return 0;
- }
+ g_signal_query (signal_id, &query);
+ g_return_if_fail (query.signal_id != 0);
+ g_return_if_fail (query.n_params < SIGNAL_MAX_PARAMS);
- handler = gtk_signal_handler_new ();
- handler->id = gtk_handler_id++;
- handler->signal_id = signal_id;
- handler->object_signal = object_signal != FALSE;
- handler->func = func;
- handler->func_data = func_data;
- handler->destroy_func = destroy_func;
- handler->after = after != FALSE;
- handler->no_marshal = no_marshal;
+ va_start (var_args, signal_id);
+ abort = gtk_signal_collect_args (args,
+ query.n_params,
+ query.param_types,
+ query.return_type,
+ var_args);
+ va_end (var_args);
- gtk_signal_handler_insert (object, handler);
- return handler->id;
+ if (!abort)
+ gtk_signal_emitv (object, signal_id, args);
}
-static GtkEmission*
-gtk_emission_new (void)
+void
+gtk_signal_emit_by_name (GtkObject *object,
+ const gchar *name,
+ ...)
{
- GtkEmission *emission;
+ GtkArg args[SIGNAL_MAX_PARAMS + 1];
+ GSignalQuery query;
+ gboolean abort;
+ va_list var_args;
- if (!gtk_free_emissions)
- {
- GtkEmission *emission_block;
- guint i;
-
- emission_block = g_new0 (GtkEmission, EMISSION_BLOCK_SIZE);
- for (i = 1; i < EMISSION_BLOCK_SIZE; i++)
- {
- (emission_block + i)->next = gtk_free_emissions;
- gtk_free_emissions = (emission_block + i);
- }
-
- emission = emission_block;
- }
- else
- {
- emission = gtk_free_emissions;
- gtk_free_emissions = emission->next;
- }
-
- emission->object = NULL;
- emission->signal_id = 0;
- emission->in_hook = 0;
- emission->next = NULL;
+ g_return_if_fail (GTK_IS_OBJECT (object));
+ g_return_if_fail (name != NULL);
- return emission;
-}
-
-static void
-gtk_emission_add (GtkEmission **emissions,
- GtkObject *object,
- guint signal_id)
-{
- GtkEmission *emission;
+ g_signal_query (g_signal_lookup (name, GTK_OBJECT_TYPE (object)), &query);
+ g_return_if_fail (query.signal_id != 0);
+ g_return_if_fail (query.n_params < SIGNAL_MAX_PARAMS);
- g_return_if_fail (emissions != NULL);
- g_return_if_fail (object != NULL);
+ va_start (var_args, name);
+ abort = gtk_signal_collect_args (args,
+ query.n_params,
+ query.param_types,
+ query.return_type,
+ var_args);
+ va_end (var_args);
- emission = gtk_emission_new ();
- emission->object = object;
- emission->signal_id = signal_id;
-
- emission->next = *emissions;
- *emissions = emission;
-}
-
-static void
-gtk_emission_remove (GtkEmission **emissions,
- GtkObject *object,
- guint signal_id)
-{
- GtkEmission *emission, *last;
-
- g_return_if_fail (emissions != NULL);
-
- last = NULL;
- emission = *emissions;
- while (emission)
- {
- if (emission->object == object && emission->signal_id == signal_id)
- {
- if (last)
- last->next = emission->next;
- else
- *emissions = emission->next;
-
- emission->next = gtk_free_emissions;
- gtk_free_emissions = emission;
- break;
- }
-
- last = emission;
- emission = last->next;
- }
-}
-
-static gint
-gtk_emission_check (GtkEmission *emission,
- GtkObject *object,
- guint signal_id)
-{
- while (emission)
- {
- if (emission->object == object && emission->signal_id == signal_id)
- return 1 + emission->in_hook;
- emission = emission->next;
- }
- return FALSE;
+ if (!abort)
+ gtk_signal_emitv (object, query.signal_id, args);
}
-static gint
-gtk_handlers_run (GtkHandler *handlers,
- GtkSignal *signal,
- GtkObject *object,
- GtkArg *params,
- gint after)
+void
+gtk_signal_emitv_by_name (GtkObject *object,
+ const gchar *name,
+ GtkArg *args)
{
- /* *signal is a local copy on the stack of gtk_signal_real_emit(),
- * so we don't need to look it up every time we invoked a function.
- */
- while (handlers && handlers->signal_id == signal->signal_id)
- {
- GtkHandler *handlers_next;
-
- gtk_signal_handler_ref (handlers);
-
- if (!handlers->blocked && handlers->after == after)
- {
- if (handlers->func)
- {
- if (handlers->no_marshal)
- (* (GtkCallbackMarshal) handlers->func) (object,
- handlers->func_data,
- signal->nparams,
- params);
- else if (handlers->object_signal)
- /* don't cast with GTK_OBJECT () */
- (* signal->marshaller) ((GtkObject*) handlers->func_data,
- handlers->func,
- object,
- params);
- else
- (* signal->marshaller) (object,
- handlers->func,
- handlers->func_data,
- params);
- }
- else if (global_marshaller)
- (* global_marshaller) (object,
- handlers->func_data,
- signal->nparams,
- params,
- signal->params,
- signal->return_val);
-
- if (stop_emissions && gtk_emission_check (stop_emissions,
- object,
- signal->signal_id))
- {
- gtk_emission_remove (&stop_emissions, object, signal->signal_id);
-
- gtk_signal_handler_unref (handlers, object);
-
- return EMISSION_DONE;
- }
- else if (restart_emissions &&
- signal->signal_flags & GTK_RUN_NO_RECURSE &&
- gtk_emission_check (restart_emissions, object, signal->signal_id))
- {
- gtk_emission_remove (&restart_emissions, object, signal->signal_id);
-
- gtk_signal_handler_unref (handlers, object);
-
- return EMISSION_RESTART;
- }
- }
-
- handlers_next = handlers->next;
- gtk_signal_handler_unref (handlers, object);
- handlers = handlers_next;
- }
+ g_return_if_fail (GTK_IS_OBJECT (object));
- return EMISSION_CONTINUE;
-}
-
-static gboolean
-gtk_signal_collect_params (GtkArg *params,
- guint n_params,
- GtkType *param_types,
- GtkType return_type,
- va_list var_args)
-{
- register GtkArg *last_param;
- register gboolean failed = FALSE;
-
- for (last_param = params + n_params; params < last_param; params++)
- {
- register gchar *error;
-
- params->name = NULL;
- params->type = *(param_types++);
- GTK_ARG_COLLECT_VALUE (params,
- var_args,
- error);
- if (error)
- {
- failed = TRUE;
- g_warning ("gtk_signal_collect_params(): %s", error);
- g_free (error);
- }
- }
-
- params->type = return_type;
- params->name = NULL;
-
- return_type = GTK_FUNDAMENTAL_TYPE (return_type);
- if (return_type != GTK_TYPE_NONE)
- {
- if (return_type != 0) /* FIXME: check for IS_PARAM */
- {
- GTK_VALUE_POINTER (*params) = va_arg (var_args, gpointer);
-
- if (GTK_VALUE_POINTER (*params) == NULL)
- {
- failed = TRUE;
- g_warning ("gtk_signal_collect_params(): invalid NULL pointer for return argument type `%s'",
- gtk_type_name (params->type));
- }
- }
- else
- {
- failed = TRUE;
- g_warning ("gtk_signal_collect_params(): unsupported return argument type `%s'",
- gtk_type_name (params->type));
- }
- }
- else
- GTK_VALUE_POINTER (*params) = NULL;
-
- return failed;
+ gtk_signal_emitv (object, g_signal_lookup (name, GTK_OBJECT_TYPE (object)), args);
}
diff --git a/gtk/gtksignal.h b/gtk/gtksignal.h
index aa4b51906..2f71b4f1e 100644
--- a/gtk/gtksignal.h
+++ b/gtk/gtksignal.h
@@ -28,178 +28,109 @@
#define __GTK_SIGNAL_H__
-#include <gdk/gdk.h>
#include <gtk/gtkenums.h>
#include <gtk/gtkobject.h>
#include <gtk/gtkmarshal.h>
+
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */
-#define GTK_SIGNAL_OFFSET(struct, field) (GTK_STRUCT_OFFSET (struct, field))
-
-
-typedef void (*GtkSignalMarshal) (GtkObject *object,
- gpointer data,
- guint nparams,
- GtkArg *args,
- GtkType *arg_types,
- GtkType return_type);
-typedef void (*GtkSignalDestroy) (gpointer data);
-typedef gboolean (*GtkEmissionHook) (GtkObject *object,
- guint signal_id,
- guint n_params,
- GtkArg *params,
- gpointer data);
-
-typedef struct _GtkSignalQuery GtkSignalQuery;
-
-struct _GtkSignalQuery
-{
- GtkType object_type;
- guint signal_id;
- const gchar *signal_name;
- guint is_user_signal : 1;
- GtkSignalRunType signal_flags;
- GtkType return_val;
- guint nparams;
- const GtkType *params;
-};
-
-
-/* Application-level methods */
-guint gtk_signal_lookup (const gchar *name,
- GtkType object_type);
-gchar* gtk_signal_name (guint signal_id) G_GNUC_CONST;
-guint gtk_signal_n_emissions (GtkObject *object,
- guint signal_id);
-guint gtk_signal_n_emissions_by_name (GtkObject *object,
- const gchar *name);
-void gtk_signal_emit_stop (GtkObject *object,
- guint signal_id);
-void gtk_signal_emit_stop_by_name (GtkObject *object,
- const gchar *name);
-guint gtk_signal_connect (GtkObject *object,
- const gchar *name,
- GtkSignalFunc func,
- gpointer func_data);
-guint gtk_signal_connect_after (GtkObject *object,
- const gchar *name,
- GtkSignalFunc func,
- gpointer func_data);
-guint gtk_signal_connect_object (GtkObject *object,
- const gchar *name,
- GtkSignalFunc func,
- GtkObject *slot_object);
-guint gtk_signal_connect_object_after (GtkObject *object,
- const gchar *name,
- GtkSignalFunc func,
- GtkObject *slot_object);
-guint gtk_signal_connect_full (GtkObject *object,
- const gchar *name,
- GtkSignalFunc func,
- GtkCallbackMarshal marshal,
- gpointer data,
- GtkDestroyNotify destroy_func,
- gint object_signal,
- gint after);
-
-void gtk_signal_connect_object_while_alive (GtkObject *object,
- const gchar *signal,
- GtkSignalFunc func,
- GtkObject *alive_object);
-void gtk_signal_connect_while_alive (GtkObject *object,
- const gchar *signal,
- GtkSignalFunc func,
- gpointer func_data,
- GtkObject *alive_object);
-
-void gtk_signal_disconnect (GtkObject *object,
- guint handler_id);
-void gtk_signal_disconnect_by_func (GtkObject *object,
- GtkSignalFunc func,
- gpointer data);
-void gtk_signal_disconnect_by_data (GtkObject *object,
- gpointer data);
-void gtk_signal_handler_block (GtkObject *object,
- guint handler_id);
-void gtk_signal_handler_block_by_func (GtkObject *object,
- GtkSignalFunc func,
- gpointer data);
-void gtk_signal_handler_block_by_data (GtkObject *object,
- gpointer data);
-void gtk_signal_handler_unblock (GtkObject *object,
- guint handler_id);
-void gtk_signal_handler_unblock_by_func (GtkObject *object,
- GtkSignalFunc func,
- gpointer data);
-void gtk_signal_handler_unblock_by_data (GtkObject *object,
- gpointer data);
-guint gtk_signal_handler_pending (GtkObject *object,
- guint signal_id,
- gboolean may_be_blocked);
-guint gtk_signal_handler_pending_by_func (GtkObject *object,
- guint signal_id,
- gboolean may_be_blocked,
- GtkSignalFunc func,
- gpointer data);
-gint gtk_signal_handler_pending_by_id (GtkObject *object,
- guint handler_id,
- gboolean may_be_blocked);
-guint gtk_signal_add_emission_hook (guint signal_id,
- GtkEmissionHook hook_func,
- gpointer data);
-guint gtk_signal_add_emission_hook_full (guint signal_id,
- GtkEmissionHook hook_func,
- gpointer data,
- GDestroyNotify destroy);
-void gtk_signal_remove_emission_hook (guint signal_id,
- guint hook_id);
-
-/* Report internal information about a signal. The caller has the
- * responsibility to invoke a subsequent g_free (returned_data); but
- * must not modify data pointed to by the members of GtkSignalQuery
- */
-GtkSignalQuery* gtk_signal_query (guint signal_id);
-
-
-/* Widget-level methods */
-void gtk_signal_init (void);
-guint gtk_signal_new (const gchar *name,
- GtkSignalRunType signal_flags,
- GtkType object_type,
- guint function_offset,
- GtkSignalMarshaller marshaller,
- GtkType return_val,
- guint nparams,
- ...);
-guint gtk_signal_newv (const gchar *name,
- GtkSignalRunType signal_flags,
- GtkType object_type,
- guint function_offset,
- GtkSignalMarshaller marshaller,
- GtkType return_val,
- guint nparams,
- GtkType *params);
-void gtk_signal_emit (GtkObject *object,
- guint signal_id,
- ...);
-void gtk_signal_emit_by_name (GtkObject *object,
- const gchar *name,
- ...);
-void gtk_signal_emitv (GtkObject *object,
- guint signal_id,
- GtkArg *params);
-void gtk_signal_emitv_by_name (GtkObject *object,
- const gchar *name,
- GtkArg *params);
-/* Non-public methods */
-void gtk_signal_handlers_destroy (GtkObject *object);
-void gtk_signal_set_funcs (GtkSignalMarshal marshal_func,
- GtkSignalDestroy destroy_func);
-
+
+#define gtk_signal_default_marshaller gtk_marshal_VOID__VOID
+
+
+/* --- compat defines --- */
+#define GTK_SIGNAL_OFFSET GTK_STRUCT_OFFSET
+#define gtk_signal_init() g_type_init()
+#define gtk_signal_lookup g_signal_lookup
+#define gtk_signal_name g_signal_name
+#define gtk_signal_emit_stop g_signal_stop_emission
+#define gtk_signal_connect(o,s,f,d) gtk_signal_connect_full ((o), (s), (f), 0, (d), 0, 0, 0)
+#define gtk_signal_connect_after(o,s,f,d) gtk_signal_connect_full ((o), (s), (f), 0, (d), 0, 0, 1)
+#define gtk_signal_connect_object(o,s,f,d) gtk_signal_connect_full ((o), (s), (f), 0, (d), 0, 1, 0)
+#define gtk_signal_connect_object_after(o,s,f,d) gtk_signal_connect_full ((o), (s), (f), 0, (d), 0, 1, 1)
+#define gtk_signal_disconnect g_signal_handler_disconnect
+#define gtk_signal_handler_block g_signal_handler_block
+#define gtk_signal_handler_unblock g_signal_handler_unblock
+#define gtk_signal_disconnect_by_func(o,f,d) gtk_signal_compat_matched ((o), (f), (d), G_SIGNAL_MATCH_FUNC | \
+ G_SIGNAL_MATCH_DATA, 0)
+#define gtk_signal_disconnect_by_data(o,d) gtk_signal_compat_matched ((o), 0, (d), G_SIGNAL_MATCH_DATA, 0)
+#define gtk_signal_handler_block_by_func(o,f,d) gtk_signal_compat_matched ((o), (f), (d), G_SIGNAL_MATCH_FUNC | \
+ G_SIGNAL_MATCH_DATA, 1)
+#define gtk_signal_handler_block_by_data(o,d) gtk_signal_compat_matched ((o), 0, (d), G_SIGNAL_MATCH_DATA, 1)
+#define gtk_signal_handler_unblock_by_func(o,f,d) gtk_signal_compat_matched ((o), (f), (d), G_SIGNAL_MATCH_FUNC | \
+ G_SIGNAL_MATCH_DATA, 2)
+#define gtk_signal_handler_unblock_by_data(o,d) gtk_signal_compat_matched ((o), 0, (d), G_SIGNAL_MATCH_DATA, 2)
+#define gtk_signal_handler_pending g_signal_has_handler_pending
+#define gtk_signal_handler_pending_by_func(o,s,b,f,d) (g_signal_handler_find ((o), G_SIGNAL_MATCH_ID | \
+ G_SIGNAL_MATCH_FUNC | \
+ G_SIGNAL_MATCH_DATA | \
+ ((b) ? 0 : G_SIGNAL_MATCH_UNBLOCKED), \
+ (s), 0, (f), (d)) != 0)
+
+
+/* --- compat functions --- */
+guint gtk_signal_newv (const gchar *name,
+ GtkSignalRunType signal_flags,
+ GtkType object_type,
+ guint function_offset,
+ GtkSignalMarshaller marshaller,
+ GtkType return_val,
+ guint n_args,
+ GtkType *args);
+guint gtk_signal_new (const gchar *name,
+ GtkSignalRunType signal_flags,
+ GtkType object_type,
+ guint function_offset,
+ GtkSignalMarshaller marshaller,
+ GtkType return_val,
+ guint n_args,
+ ...);
+void gtk_signal_emit_stop_by_name (GtkObject *object,
+ const gchar *name);
+void gtk_signal_connect_object_while_alive (GtkObject *object,
+ const gchar *signal,
+ GtkSignalFunc func,
+ GtkObject *alive_object);
+void gtk_signal_connect_while_alive (GtkObject *object,
+ const gchar *signal,
+ GtkSignalFunc func,
+ gpointer func_data,
+ GtkObject *alive_object);
+guint gtk_signal_connect_full (GtkObject *object,
+ const gchar *name,
+ GtkSignalFunc func,
+ GtkCallbackMarshal unsupported,
+ gpointer data,
+ GtkDestroyNotify destroy_func,
+ gint object_signal,
+ gint after);
+void gtk_signal_emitv (GtkObject *object,
+ guint signal_id,
+ GtkArg *args);
+void gtk_signal_emit (GtkObject *object,
+ guint signal_id,
+ ...);
+void gtk_signal_emit_by_name (GtkObject *object,
+ const gchar *name,
+ ...);
+void gtk_signal_emitv_by_name (GtkObject *object,
+ const gchar *name,
+ GtkArg *args);
+void gtk_signal_compat_matched (GtkObject *object,
+ GtkSignalFunc func,
+ gpointer data,
+ GSignalMatchType match,
+ guint action);
+
+
+/* FIXME: non-functional relicts */
+typedef gpointer GtkEmissionHook;
+#define gtk_signal_add_emission_hook(i,h,d) (0)
+#define gtk_signal_remove_emission_hook(i,h) while (0)
#ifdef __cplusplus
diff --git a/gtk/gtksocket.c b/gtk/gtksocket.c
index 067bf4428..648cedc48 100644
--- a/gtk/gtksocket.c
+++ b/gtk/gtksocket.c
@@ -92,7 +92,7 @@ gtk_socket_get_type (void)
(GInstanceInitFunc) gtk_socket_init,
};
- socket_type = g_type_register_static (GTK_TYPE_CONTAINER, "GtkSocket", &socket_info);
+ socket_type = g_type_register_static (GTK_TYPE_CONTAINER, "GtkSocket", &socket_info, 0);
}
return socket_type;
diff --git a/gtk/gtkspinbutton.c b/gtk/gtkspinbutton.c
index 9b400cefa..4193ba28a 100644
--- a/gtk/gtkspinbutton.c
+++ b/gtk/gtkspinbutton.c
@@ -248,7 +248,7 @@ gtk_spin_button_class_init (GtkSpinButtonClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkSpinButtonClass, output),
- gtk_marshal_BOOL__NONE,
+ gtk_marshal_BOOLEAN__VOID,
GTK_TYPE_BOOL, 0);
gtk_object_class_add_signals (object_class, spinbutton_signals, LAST_SIGNAL);
diff --git a/gtk/gtkstatusbar.c b/gtk/gtkstatusbar.c
index 6e0ba3b79..c5bb68b9d 100644
--- a/gtk/gtkstatusbar.c
+++ b/gtk/gtkstatusbar.c
@@ -101,7 +101,7 @@ gtk_statusbar_class_init (GtkStatusbarClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkStatusbarClass, text_pushed),
- gtk_marshal_NONE__UINT_STRING,
+ gtk_marshal_VOID__UINT_STRING,
GTK_TYPE_NONE, 2,
GTK_TYPE_UINT,
GTK_TYPE_STRING);
@@ -110,7 +110,7 @@ gtk_statusbar_class_init (GtkStatusbarClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkStatusbarClass, text_popped),
- gtk_marshal_NONE__UINT_STRING,
+ gtk_marshal_VOID__UINT_STRING,
GTK_TYPE_NONE, 2,
GTK_TYPE_UINT,
GTK_TYPE_STRING);
diff --git a/gtk/gtkstyle.c b/gtk/gtkstyle.c
index 087bcb12e..69e9f681c 100644
--- a/gtk/gtkstyle.c
+++ b/gtk/gtkstyle.c
@@ -359,7 +359,7 @@ gtk_style_get_type (void)
object_type = g_type_register_static (G_TYPE_OBJECT,
"GtkStyle",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gtk/gtktext.c b/gtk/gtktext.c
index 7953deed2..5994b1949 100644
--- a/gtk/gtktext.c
+++ b/gtk/gtktext.c
@@ -609,7 +609,7 @@ gtk_text_class_init (GtkTextClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextClass, set_scroll_adjustments),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE, 2, GTK_TYPE_ADJUSTMENT, GTK_TYPE_ADJUSTMENT);
}
diff --git a/gtk/gtktextbuffer.c b/gtk/gtktextbuffer.c
index 557bd6bf5..739cfe69b 100644
--- a/gtk/gtktextbuffer.c
+++ b/gtk/gtktextbuffer.c
@@ -96,11 +96,6 @@ static void gtk_text_buffer_real_remove_tag (GtkTextBuffer *buffe
static GtkTextBTree* get_btree (GtkTextBuffer *buffer);
-void gtk_marshal_NONE__INT_POINTER_INT (GtkObject *object,
- GtkSignalFunc func,
- gpointer func_data,
- GtkArg *args);
-
static GtkObjectClass *parent_class = NULL;
static guint signals[LAST_SIGNAL] = { 0 };
@@ -142,7 +137,7 @@ gtk_text_buffer_class_init (GtkTextBufferClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextBufferClass, insert_text),
- gtk_marshal_NONE__POINTER_POINTER_INT_INT,
+ gtk_marshal_VOID__POINTER_POINTER_INT_INT,
GTK_TYPE_NONE,
4,
GTK_TYPE_POINTER,
@@ -155,7 +150,7 @@ gtk_text_buffer_class_init (GtkTextBufferClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextBufferClass, delete_text),
- gtk_marshal_NONE__POINTER_POINTER_INT,
+ gtk_marshal_VOID__POINTER_POINTER_INT,
GTK_TYPE_NONE,
3,
GTK_TYPE_POINTER,
@@ -167,7 +162,7 @@ gtk_text_buffer_class_init (GtkTextBufferClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextBufferClass, changed),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE,
0);
@@ -176,7 +171,7 @@ gtk_text_buffer_class_init (GtkTextBufferClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextBufferClass, modified_changed),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE,
0);
@@ -185,7 +180,7 @@ gtk_text_buffer_class_init (GtkTextBufferClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextBufferClass, mark_set),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE,
2,
GTK_TYPE_POINTER,
@@ -196,7 +191,7 @@ gtk_text_buffer_class_init (GtkTextBufferClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextBufferClass, mark_deleted),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE,
1,
GTK_TYPE_POINTER);
@@ -206,7 +201,7 @@ gtk_text_buffer_class_init (GtkTextBufferClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextBufferClass, apply_tag),
- gtk_marshal_NONE__POINTER_POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER_POINTER,
GTK_TYPE_NONE,
3,
GTK_TYPE_POINTER,
@@ -218,7 +213,7 @@ gtk_text_buffer_class_init (GtkTextBufferClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextBufferClass, remove_tag),
- gtk_marshal_NONE__POINTER_POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER_POINTER,
GTK_TYPE_NONE,
3,
GTK_TYPE_POINTER,
@@ -237,30 +232,6 @@ gtk_text_buffer_class_init (GtkTextBufferClass *klass)
klass->remove_tag = gtk_text_buffer_real_remove_tag;
}
-
-typedef gint (*GtkSignal_NONE__INT_POINTER_INT) (GtkObject *object,
- gint pos,
- const gchar *text,
- gint len,
- gpointer user_data);
-
-void
-gtk_marshal_NONE__INT_POINTER_INT (GtkObject *object,
- GtkSignalFunc func,
- gpointer func_data,
- GtkArg *args)
-{
- GtkSignal_NONE__INT_POINTER_INT rfunc;
-
- rfunc = (GtkSignal_NONE__INT_POINTER_INT) func;
-
- (*rfunc) (object,
- GTK_VALUE_INT (args[0]),
- GTK_VALUE_POINTER (args[1]),
- GTK_VALUE_INT (args[2]),
- func_data);
-}
-
void
gtk_text_buffer_init (GtkTextBuffer *buffer)
{
diff --git a/gtk/gtktextlayout.c b/gtk/gtktextlayout.c
index 99e3c39c4..363aafbca 100644
--- a/gtk/gtktextlayout.c
+++ b/gtk/gtktextlayout.c
@@ -101,10 +101,6 @@ static void gtk_text_layout_class_init (GtkTextLayoutClass *klass);
static void gtk_text_layout_destroy (GtkObject *object);
static void gtk_text_layout_finalize (GObject *object);
-void gtk_marshal_NONE__INT_INT_INT_INT (GtkObject *object,
- GtkSignalFunc func,
- gpointer func_data,
- GtkArg *args);
static GtkObjectClass *parent_class = NULL;
static guint signals[LAST_SIGNAL] = { 0 };
@@ -149,7 +145,7 @@ gtk_text_layout_class_init (GtkTextLayoutClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextLayoutClass, invalidated),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE,
0);
@@ -158,7 +154,7 @@ gtk_text_layout_class_init (GtkTextLayoutClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextLayoutClass, changed),
- gtk_marshal_NONE__INT_INT_INT,
+ gtk_marshal_VOID__INT_INT_INT,
GTK_TYPE_NONE,
3,
GTK_TYPE_INT,
@@ -2284,28 +2280,6 @@ gtk_text_layout_move_iter_visually (GtkTextLayout *layout,
}
-typedef void (*GtkSignal_NONE__INT_INT_INT_INT) (GtkObject *object,
- gint x, gint y,
- gint width, gint height,
- gpointer user_data);
-
-void
-gtk_marshal_NONE__INT_INT_INT_INT (GtkObject *object,
- GtkSignalFunc func,
- gpointer func_data,
- GtkArg *args)
-{
- GtkSignal_NONE__INT_INT_INT_INT rfunc;
-
- rfunc = (GtkSignal_NONE__INT_INT_INT_INT) func;
- (*rfunc) (object,
- GTK_VALUE_INT (args[0]),
- GTK_VALUE_INT (args[1]),
- GTK_VALUE_INT (args[2]),
- GTK_VALUE_INT (args[3]),
- func_data);
-}
-
void
gtk_text_layout_spew (GtkTextLayout *layout)
{
diff --git a/gtk/gtktextmark.c b/gtk/gtktextmark.c
index c66af21e2..72adca897 100644
--- a/gtk/gtktextmark.c
+++ b/gtk/gtktextmark.c
@@ -79,7 +79,7 @@ gtk_text_mark_get_type (void)
object_type = g_type_register_static (G_TYPE_OBJECT,
"GtkTextMark",
- &object_info);
+ &object_info, 0);
}
return object_type;
diff --git a/gtk/gtktexttagtable.c b/gtk/gtktexttagtable.c
index 57f23ec4e..3d3d436f2 100644
--- a/gtk/gtktexttagtable.c
+++ b/gtk/gtktexttagtable.c
@@ -63,7 +63,7 @@ gtk_text_tag_table_class_init (GtkTextTagTableClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextTagTableClass, tag_changed),
- gtk_marshal_NONE__POINTER_INT,
+ gtk_marshal_VOID__POINTER_INT,
GTK_TYPE_NONE,
2,
GTK_TYPE_OBJECT,
@@ -74,7 +74,7 @@ gtk_text_tag_table_class_init (GtkTextTagTableClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextTagTableClass, tag_added),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE,
1,
GTK_TYPE_OBJECT);
@@ -84,7 +84,7 @@ gtk_text_tag_table_class_init (GtkTextTagTableClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextTagTableClass, tag_removed),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE,
1,
GTK_TYPE_OBJECT);
diff --git a/gtk/gtktextview.c b/gtk/gtktextview.c
index 9bec94ce6..bab192c87 100644
--- a/gtk/gtktextview.c
+++ b/gtk/gtktextview.c
@@ -383,7 +383,7 @@ gtk_text_view_class_init (GtkTextViewClass *klass)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextViewClass, move),
- gtk_marshal_NONE__INT_INT_INT,
+ gtk_marshal_VOID__INT_INT_INT,
GTK_TYPE_NONE, 3, GTK_TYPE_MOVEMENT_STEP, GTK_TYPE_INT, GTK_TYPE_BOOL);
signals[SET_ANCHOR] =
@@ -391,7 +391,7 @@ gtk_text_view_class_init (GtkTextViewClass *klass)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextViewClass, set_anchor),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
signals[INSERT] =
@@ -399,7 +399,7 @@ gtk_text_view_class_init (GtkTextViewClass *klass)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextViewClass, insert),
- gtk_marshal_NONE__STRING,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1, GTK_TYPE_STRING);
signals[DELETE] =
@@ -407,7 +407,7 @@ gtk_text_view_class_init (GtkTextViewClass *klass)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextViewClass, delete),
- gtk_marshal_NONE__INT_INT,
+ gtk_marshal_VOID__INT_INT,
GTK_TYPE_NONE, 2, GTK_TYPE_DELETE_TYPE, GTK_TYPE_INT);
signals[CUT_CLIPBOARD] =
@@ -415,7 +415,7 @@ gtk_text_view_class_init (GtkTextViewClass *klass)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextViewClass, cut_clipboard),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
signals[COPY_CLIPBOARD] =
@@ -423,7 +423,7 @@ gtk_text_view_class_init (GtkTextViewClass *klass)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextViewClass, copy_clipboard),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
signals[PASTE_CLIPBOARD] =
@@ -431,7 +431,7 @@ gtk_text_view_class_init (GtkTextViewClass *klass)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextViewClass, paste_clipboard),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
signals[TOGGLE_OVERWRITE] =
@@ -439,7 +439,7 @@ gtk_text_view_class_init (GtkTextViewClass *klass)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextViewClass, toggle_overwrite),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
signals[SET_SCROLL_ADJUSTMENTS] = widget_class->set_scroll_adjustments_signal =
@@ -447,7 +447,7 @@ gtk_text_view_class_init (GtkTextViewClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTextViewClass, set_scroll_adjustments),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE, 2, GTK_TYPE_ADJUSTMENT, GTK_TYPE_ADJUSTMENT);
gtk_object_class_add_signals (object_class, signals, LAST_SIGNAL);
diff --git a/gtk/gtkthemes.c b/gtk/gtkthemes.c
index 666e4b1a4..61b7fc182 100644
--- a/gtk/gtkthemes.c
+++ b/gtk/gtkthemes.c
@@ -305,7 +305,7 @@ gtk_theme_engine_register_type (GtkThemeEngine *engine,
plugin->engine = NULL;
plugin->engine_name = NULL;
plugin->parent_type = parent_type;
- plugin->type = g_type_register_dynamic (parent_type, type_name, (GTypePlugin *)plugin);
+ plugin->type = g_type_register_dynamic (parent_type, type_name, (GTypePlugin *) plugin, 0);
}
if (plugin->engine)
diff --git a/gtk/gtktipsquery.c b/gtk/gtktipsquery.c
index 81aa34c14..a07328745 100644
--- a/gtk/gtktipsquery.c
+++ b/gtk/gtktipsquery.c
@@ -127,21 +127,21 @@ gtk_tips_query_class_init (GtkTipsQueryClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTipsQueryClass, start_query),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
tips_query_signals[SIGNAL_STOP_QUERY] =
gtk_signal_new ("stop_query",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTipsQueryClass, stop_query),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
tips_query_signals[SIGNAL_WIDGET_ENTERED] =
gtk_signal_new ("widget_entered",
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTipsQueryClass, widget_entered),
- gtk_marshal_NONE__POINTER_STRING_STRING,
+ gtk_marshal_VOID__POINTER_STRING_STRING,
GTK_TYPE_NONE, 3,
GTK_TYPE_WIDGET,
GTK_TYPE_STRING,
@@ -151,7 +151,7 @@ gtk_tips_query_class_init (GtkTipsQueryClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTipsQueryClass, widget_selected),
- gtk_marshal_BOOL__POINTER_STRING_STRING_POINTER,
+ gtk_marshal_BOOLEAN__POINTER_STRING_STRING_POINTER,
GTK_TYPE_BOOL, 4,
GTK_TYPE_WIDGET,
GTK_TYPE_STRING,
diff --git a/gtk/gtktogglebutton.c b/gtk/gtktogglebutton.c
index 849dc8a64..5b70c7e04 100644
--- a/gtk/gtktogglebutton.c
+++ b/gtk/gtktogglebutton.c
@@ -124,7 +124,7 @@ gtk_toggle_button_class_init (GtkToggleButtonClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkToggleButtonClass, toggled),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, toggle_button_signals, LAST_SIGNAL);
diff --git a/gtk/gtktoolbar.c b/gtk/gtktoolbar.c
index 28178d7f2..24b4412f7 100644
--- a/gtk/gtktoolbar.c
+++ b/gtk/gtktoolbar.c
@@ -145,7 +145,7 @@ gtk_toolbar_class_init (GtkToolbarClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkToolbarClass, orientation_changed),
- gtk_marshal_NONE__INT,
+ gtk_marshal_VOID__INT,
GTK_TYPE_NONE, 1,
GTK_TYPE_INT);
toolbar_signals[STYLE_CHANGED] =
@@ -153,7 +153,7 @@ gtk_toolbar_class_init (GtkToolbarClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkToolbarClass, style_changed),
- gtk_marshal_NONE__INT,
+ gtk_marshal_VOID__INT,
GTK_TYPE_NONE, 1,
GTK_TYPE_INT);
diff --git a/gtk/gtktree.c b/gtk/gtktree.c
index 954516c02..bc17a19b6 100644
--- a/gtk/gtktree.c
+++ b/gtk/gtktree.c
@@ -117,14 +117,14 @@ gtk_tree_class_init (GtkTreeClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeClass, selection_changed),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
tree_signals[SELECT_CHILD] =
gtk_signal_new ("select_child",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeClass, select_child),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_WIDGET);
tree_signals[UNSELECT_CHILD] =
@@ -132,7 +132,7 @@ gtk_tree_class_init (GtkTreeClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeClass, unselect_child),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_WIDGET);
diff --git a/gtk/gtktreeitem.c b/gtk/gtktreeitem.c
index e93c0727d..9ab2e75df 100644
--- a/gtk/gtktreeitem.c
+++ b/gtk/gtktreeitem.c
@@ -147,14 +147,14 @@ gtk_tree_item_class_init (GtkTreeItemClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeItemClass, expand),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
tree_item_signals[COLLAPSE_TREE] =
gtk_signal_new ("collapse",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeItemClass, collapse),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, tree_item_signals, LAST_SIGNAL);
diff --git a/gtk/gtktreemodel.c b/gtk/gtktreemodel.c
index aaee6974a..a4c8f69d4 100644
--- a/gtk/gtktreemodel.c
+++ b/gtk/gtktreemodel.c
@@ -42,7 +42,7 @@ gtk_tree_model_get_type (void)
NULL, /* base_finalize */
};
- tree_model_type = g_type_register_static (G_TYPE_INTERFACE, "GtkTreeModel", &tree_model_info);
+ tree_model_type = g_type_register_static (G_TYPE_INTERFACE, "GtkTreeModel", &tree_model_info, 0);
}
return tree_model_type;
diff --git a/gtk/gtktreeselection.c b/gtk/gtktreeselection.c
index 6c76bf8c6..802d806ec 100644
--- a/gtk/gtktreeselection.c
+++ b/gtk/gtktreeselection.c
@@ -59,7 +59,7 @@ gtk_tree_selection_get_type (void)
(GInstanceInitFunc) gtk_tree_selection_init
};
- selection_type = g_type_register_static (GTK_TYPE_OBJECT, "GtkTreeSelection", &selection_info);
+ selection_type = g_type_register_static (GTK_TYPE_OBJECT, "GtkTreeSelection", &selection_info, 0);
}
return selection_type;
@@ -78,7 +78,7 @@ gtk_tree_selection_class_init (GtkTreeSelectionClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeSelectionClass, selection_changed),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, tree_selection_signals, LAST_SIGNAL);
diff --git a/gtk/gtktreestore.c b/gtk/gtktreestore.c
index a34015a6a..96daafe89 100644
--- a/gtk/gtktreestore.c
+++ b/gtk/gtktreestore.c
@@ -90,7 +90,7 @@ gtk_tree_store_get_type (void)
NULL
};
- tree_store_type = g_type_register_static (GTK_TYPE_OBJECT, "GtkTreeStore", &tree_store_info);
+ tree_store_type = g_type_register_static (GTK_TYPE_OBJECT, "GtkTreeStore", &tree_store_info, 0);
g_type_add_interface_static (tree_store_type,
GTK_TYPE_TREE_MODEL,
&tree_model_info);
@@ -111,7 +111,7 @@ gtk_tree_store_class_init (GtkTreeStoreClass *tree_store_class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeStoreClass, node_changed),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE, 2,
GTK_TYPE_POINTER,
GTK_TYPE_POINTER);
@@ -120,7 +120,7 @@ gtk_tree_store_class_init (GtkTreeStoreClass *tree_store_class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeStoreClass, node_inserted),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE, 2,
GTK_TYPE_POINTER,
GTK_TYPE_POINTER);
@@ -129,7 +129,7 @@ gtk_tree_store_class_init (GtkTreeStoreClass *tree_store_class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeStoreClass, node_child_toggled),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE, 2,
GTK_TYPE_POINTER,
GTK_TYPE_POINTER);
@@ -138,7 +138,7 @@ gtk_tree_store_class_init (GtkTreeStoreClass *tree_store_class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeStoreClass, node_deleted),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_POINTER);
diff --git a/gtk/gtktreeview.c b/gtk/gtktreeview.c
index 6f0b4ab4d..e95110783 100644
--- a/gtk/gtktreeview.c
+++ b/gtk/gtktreeview.c
@@ -180,7 +180,7 @@ gtk_tree_view_get_type (void)
(GInstanceInitFunc) gtk_tree_view_init
};
- tree_view_type = g_type_register_static (GTK_TYPE_CONTAINER, "GtkTreeView", &tree_view_info);
+ tree_view_type = g_type_register_static (GTK_TYPE_CONTAINER, "GtkTreeView", &tree_view_info, 0);
}
return tree_view_type;
@@ -226,7 +226,7 @@ gtk_tree_view_class_init (GtkTreeViewClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeViewClass, set_scroll_adjustments),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE, 2,
GTK_TYPE_POINTER, GTK_TYPE_POINTER);
}
diff --git a/gtk/gtktreeviewcolumn.c b/gtk/gtktreeviewcolumn.c
index fa032ee1e..f8810d724 100644
--- a/gtk/gtktreeviewcolumn.c
+++ b/gtk/gtktreeviewcolumn.c
@@ -61,7 +61,7 @@ gtk_tree_view_column_get_type (void)
(GInstanceInitFunc) gtk_tree_view_column_init,
};
- tree_column_type = g_type_register_static (GTK_TYPE_OBJECT, "GtkTreeViewColumn", &tree_column_info);
+ tree_column_type = g_type_register_static (GTK_TYPE_OBJECT, "GtkTreeViewColumn", &tree_column_info, 0);
}
return tree_column_type;
@@ -81,7 +81,7 @@ gtk_tree_view_column_class_init (GtkTreeViewColumnClass *class)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkTreeViewColumnClass, clicked),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
gtk_object_class_add_signals (object_class, tree_column_signals, LAST_SIGNAL);
diff --git a/gtk/gtktypeutils.c b/gtk/gtktypeutils.c
index fa8996a8a..235b461d9 100644
--- a/gtk/gtktypeutils.c
+++ b/gtk/gtktypeutils.c
@@ -50,7 +50,7 @@ gtk_type_unique (GtkType parent_type,
tinfo.n_preallocs = 0;
tinfo.instance_init = gtkinfo->object_init_func;
- return g_type_register_static (parent_type, gtkinfo->type_name, &tinfo);
+ return g_type_register_static (parent_type, gtkinfo->type_name, &tinfo, 0);
}
gpointer
@@ -118,6 +118,9 @@ GType GTK_TYPE_IDENTIFIER = 0;
#endif
extern IMPORT gboolean glib_debug_objects;
+#include <gtk.h> /* for gtktypebuiltins_ids.c */
+#include <gdk.h> /* gtktypebuiltins_ids.c */
+
void
gtk_type_init (void)
{
@@ -129,14 +132,14 @@ gtk_type_init (void)
GtkType type_id;
gchar *name;
} fundamental_info[] = {
- { GTK_TYPE_POINTER, "gpointer" },
{ GTK_TYPE_SIGNAL, "GtkSignal" },
};
static struct {
gchar *type_name;
GtkType *type_id;
GtkType parent;
- const GtkEnumValue *values;
+ gconstpointer pointer1;
+ gpointer pointer2;
} builtin_info[GTK_TYPE_N_BUILTINS + 1] = {
#include "gtktypebuiltins_ids.c" /* type entries */
{ NULL }
@@ -148,7 +151,7 @@ gtk_type_init (void)
initialized = TRUE;
- glib_debug_objects = gtk_debug_flags & GTK_DEBUG_OBJECTS != 0;
+ glib_debug_objects = (gtk_debug_flags & GTK_DEBUG_OBJECTS) != 0;
/* initialize GLib type system
*/
@@ -164,20 +167,13 @@ gtk_type_init (void)
{
type_id = g_type_register_fundamental (fundamental_info[i].type_id,
fundamental_info[i].name,
- &tinfo,
- &finfo);
+ &tinfo, &finfo, 0);
g_assert (type_id == fundamental_info[i].type_id);
}
/* GTK_TYPE_IDENTIFIER
*/
- GTK_TYPE_IDENTIFIER = g_type_register_static (G_TYPE_STRING, "GtkIdentifier", &tinfo);
-
- /* GTK_TYPE_BOXED
- */
- finfo.type_flags = G_TYPE_FLAG_DERIVABLE;
- type_id = g_type_register_fundamental (GTK_TYPE_BOXED, "GtkBoxed", &tinfo, &finfo);
- g_assert (type_id == GTK_TYPE_BOXED);
+ GTK_TYPE_IDENTIFIER = g_type_register_static (G_TYPE_STRING, "GtkIdentifier", &tinfo, 0);
/* enums and flags
*/
@@ -186,11 +182,18 @@ gtk_type_init (void)
GtkType type_id = 0;
if (builtin_info[i].parent == G_TYPE_ENUM)
- type_id = g_enum_register_static (builtin_info[i].type_name, builtin_info[i].values);
+ type_id = g_enum_register_static (builtin_info[i].type_name, builtin_info[i].pointer1);
else if (builtin_info[i].parent == G_TYPE_FLAGS)
- type_id = g_flags_register_static (builtin_info[i].type_name, (const GFlagsValue *)builtin_info[i].values);
+ type_id = g_flags_register_static (builtin_info[i].type_name, builtin_info[i].pointer1);
else if (builtin_info[i].parent == GTK_TYPE_BOXED)
- type_id = g_type_register_static (GTK_TYPE_BOXED, builtin_info[i].type_name, &tinfo);
+ {
+ if (builtin_info[i].pointer1 && builtin_info[i].pointer2)
+ type_id = g_boxed_type_register_static (builtin_info[i].type_name,
+ builtin_info[i].pointer1,
+ builtin_info[i].pointer2);
+ else
+ type_id = g_type_register_static (GTK_TYPE_BOXED, builtin_info[i].type_name, &tinfo, 0);
+ }
else
g_assert_not_reached ();
diff --git a/gtk/gtktypeutils.h b/gtk/gtktypeutils.h
index 4a2adac35..0f42429c6 100644
--- a/gtk/gtktypeutils.h
+++ b/gtk/gtktypeutils.h
@@ -58,8 +58,8 @@ typedef enum /*< skip >*/
GTK_TYPE_FLOAT = G_TYPE_FLOAT,
GTK_TYPE_DOUBLE = G_TYPE_DOUBLE,
GTK_TYPE_STRING = G_TYPE_STRING,
- GTK_TYPE_BOXED = G_TYPE_GTK_BOXED,
- GTK_TYPE_POINTER = G_TYPE_GTK_POINTER,
+ GTK_TYPE_BOXED = G_TYPE_BOXED,
+ GTK_TYPE_POINTER = G_TYPE_POINTER,
GTK_TYPE_SIGNAL = G_TYPE_GTK_SIGNAL
} GtkFundamentalType;
@@ -122,10 +122,7 @@ typedef void (*GtkCallbackMarshal) (GtkObject *object,
guint n_args,
GtkArg *args);
typedef void (*GtkSignalFunc) ();
-typedef void (*GtkSignalMarshaller) (GtkObject *object,
- GtkSignalFunc func,
- gpointer func_data,
- GtkArg *args);
+typedef GSignalCMarshaller GtkSignalMarshaller;
#define GTK_SIGNAL_FUNC(f) ((GtkSignalFunc) (f))
diff --git a/gtk/gtkviewport.c b/gtk/gtkviewport.c
index 370faf566..33282140a 100644
--- a/gtk/gtkviewport.c
+++ b/gtk/gtkviewport.c
@@ -145,7 +145,7 @@ gtk_viewport_class_init (GtkViewportClass *class)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkViewportClass, set_scroll_adjustments),
- gtk_marshal_NONE__POINTER_POINTER,
+ gtk_marshal_VOID__POINTER_POINTER,
GTK_TYPE_NONE, 2, GTK_TYPE_ADJUSTMENT, GTK_TYPE_ADJUSTMENT);
}
diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c
index e9a2b3160..43d0573f2 100644
--- a/gtk/gtkwidget.c
+++ b/gtk/gtkwidget.c
@@ -361,49 +361,49 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, show),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
widget_signals[HIDE] =
gtk_signal_new ("hide",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, hide),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
widget_signals[MAP] =
gtk_signal_new ("map",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, map),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
widget_signals[UNMAP] =
gtk_signal_new ("unmap",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, unmap),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
widget_signals[REALIZE] =
gtk_signal_new ("realize",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, realize),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
widget_signals[UNREALIZE] =
gtk_signal_new ("unrealize",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, unrealize),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
widget_signals[DRAW] =
gtk_signal_new ("draw",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, draw),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_POINTER);
widget_signals[DRAW_FOCUS] =
@@ -411,21 +411,21 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, draw_focus),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
widget_signals[DRAW_DEFAULT] =
gtk_signal_new ("draw_default",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, draw_default),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
widget_signals[SIZE_REQUEST] =
gtk_signal_new ("size_request",
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, size_request),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_POINTER);
widget_signals[SIZE_ALLOCATE] =
@@ -433,7 +433,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, size_allocate),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_POINTER);
widget_signals[STATE_CHANGED] =
@@ -441,7 +441,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, state_changed),
- gtk_marshal_NONE__UINT,
+ gtk_marshal_VOID__ENUM,
GTK_TYPE_NONE, 1,
GTK_TYPE_STATE_TYPE);
widget_signals[PARENT_SET] =
@@ -449,7 +449,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, parent_set),
- gtk_marshal_NONE__OBJECT,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_OBJECT);
widget_signals[STYLE_SET] =
@@ -457,7 +457,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, style_set),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_STYLE);
widget_signals[DIRECTION_CHANGED] =
@@ -465,7 +465,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_FIRST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, direction_changed),
- gtk_marshal_NONE__UINT,
+ gtk_marshal_VOID__ENUM,
GTK_TYPE_NONE, 1,
GTK_TYPE_TEXT_DIRECTION);
widget_signals[ADD_ACCELERATOR] =
@@ -479,14 +479,14 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, grab_focus),
- gtk_marshal_NONE__NONE,
+ gtk_marshal_VOID__VOID,
GTK_TYPE_NONE, 0);
widget_signals[EVENT] =
gtk_signal_new ("event",
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[BUTTON_PRESS_EVENT] =
@@ -494,7 +494,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, button_press_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[BUTTON_RELEASE_EVENT] =
@@ -502,7 +502,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, button_release_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[SCROLL_EVENT] =
@@ -510,7 +510,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, scroll_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[MOTION_NOTIFY_EVENT] =
@@ -518,7 +518,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, motion_notify_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[DELETE_EVENT] =
@@ -526,7 +526,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, delete_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[DESTROY_EVENT] =
@@ -534,7 +534,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, destroy_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[EXPOSE_EVENT] =
@@ -542,7 +542,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, expose_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[KEY_PRESS_EVENT] =
@@ -550,7 +550,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, key_press_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[KEY_RELEASE_EVENT] =
@@ -558,7 +558,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, key_release_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[ENTER_NOTIFY_EVENT] =
@@ -566,7 +566,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, enter_notify_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[LEAVE_NOTIFY_EVENT] =
@@ -574,7 +574,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, leave_notify_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[CONFIGURE_EVENT] =
@@ -582,7 +582,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, configure_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[FOCUS_IN_EVENT] =
@@ -590,7 +590,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, focus_in_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[FOCUS_OUT_EVENT] =
@@ -598,7 +598,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, focus_out_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[MAP_EVENT] =
@@ -606,7 +606,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, map_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[UNMAP_EVENT] =
@@ -614,7 +614,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, unmap_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[PROPERTY_NOTIFY_EVENT] =
@@ -622,7 +622,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, property_notify_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[SELECTION_CLEAR_EVENT] =
@@ -630,7 +630,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, selection_clear_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[SELECTION_REQUEST_EVENT] =
@@ -638,7 +638,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, selection_request_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[SELECTION_NOTIFY_EVENT] =
@@ -646,7 +646,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, selection_notify_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[SELECTION_RECEIVED] =
@@ -654,7 +654,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, selection_received),
- gtk_marshal_NONE__POINTER_UINT,
+ gtk_marshal_VOID__POINTER_UINT,
GTK_TYPE_NONE, 2,
GTK_TYPE_SELECTION_DATA,
GTK_TYPE_UINT);
@@ -663,7 +663,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, selection_get),
- gtk_marshal_NONE__POINTER_UINT_UINT,
+ gtk_marshal_VOID__POINTER_UINT_UINT,
GTK_TYPE_NONE, 3,
GTK_TYPE_SELECTION_DATA,
GTK_TYPE_UINT,
@@ -673,7 +673,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, proximity_in_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[PROXIMITY_OUT_EVENT] =
@@ -681,7 +681,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, proximity_out_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[DRAG_LEAVE] =
@@ -689,7 +689,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, drag_leave),
- gtk_marshal_NONE__POINTER_UINT,
+ gtk_marshal_VOID__POINTER_UINT,
GTK_TYPE_NONE, 2,
GDK_TYPE_DRAG_CONTEXT,
GTK_TYPE_UINT);
@@ -698,7 +698,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, drag_begin),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GDK_TYPE_DRAG_CONTEXT);
widget_signals[DRAG_END] =
@@ -706,7 +706,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, drag_end),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GDK_TYPE_DRAG_CONTEXT);
widget_signals[DRAG_DATA_DELETE] =
@@ -714,7 +714,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, drag_data_delete),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GDK_TYPE_DRAG_CONTEXT);
widget_signals[DRAG_MOTION] =
@@ -722,7 +722,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, drag_motion),
- gtk_marshal_BOOL__POINTER_INT_INT_UINT,
+ gtk_marshal_BOOLEAN__POINTER_INT_INT_UINT,
GTK_TYPE_BOOL, 4,
GDK_TYPE_DRAG_CONTEXT,
GTK_TYPE_INT,
@@ -733,7 +733,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, drag_drop),
- gtk_marshal_BOOL__POINTER_INT_INT_UINT,
+ gtk_marshal_BOOLEAN__POINTER_INT_INT_UINT,
GTK_TYPE_BOOL, 4,
GDK_TYPE_DRAG_CONTEXT,
GTK_TYPE_INT,
@@ -744,7 +744,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, drag_data_get),
- gtk_marshal_NONE__POINTER_POINTER_UINT_UINT,
+ gtk_marshal_VOID__POINTER_POINTER_UINT_UINT,
GTK_TYPE_NONE, 4,
GDK_TYPE_DRAG_CONTEXT,
GTK_TYPE_SELECTION_DATA,
@@ -755,7 +755,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, drag_data_received),
- gtk_marshal_NONE__POINTER_INT_INT_POINTER_UINT_UINT,
+ gtk_marshal_VOID__POINTER_INT_INT_POINTER_UINT_UINT,
GTK_TYPE_NONE, 6,
GDK_TYPE_DRAG_CONTEXT,
GTK_TYPE_INT,
@@ -768,7 +768,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, visibility_notify_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[CLIENT_EVENT] =
@@ -776,7 +776,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, client_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[NO_EXPOSE_EVENT] =
@@ -784,7 +784,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, no_expose_event),
- gtk_marshal_BOOL__POINTER,
+ gtk_marshal_BOOLEAN__POINTER,
GTK_TYPE_BOOL, 1,
GTK_TYPE_GDK_EVENT);
widget_signals[DEBUG_MSG] =
@@ -792,7 +792,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
GTK_RUN_LAST | GTK_RUN_ACTION,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWidgetClass, debug_msg),
- gtk_marshal_NONE__STRING,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_STRING);
diff --git a/gtk/gtkwindow.c b/gtk/gtkwindow.c
index 481f1d2c7..dbf9ecaf8 100644
--- a/gtk/gtkwindow.c
+++ b/gtk/gtkwindow.c
@@ -234,7 +234,7 @@ gtk_window_class_init (GtkWindowClass *klass)
GTK_RUN_LAST,
GTK_CLASS_TYPE (object_class),
GTK_SIGNAL_OFFSET (GtkWindowClass, set_focus),
- gtk_marshal_NONE__POINTER,
+ gtk_marshal_VOID__POINTER,
GTK_TYPE_NONE, 1,
GTK_TYPE_WIDGET);
diff --git a/gtk/maketypes.awk b/gtk/maketypes.awk
index 0c82cf3a2..3455f2c73 100644
--- a/gtk/maketypes.awk
+++ b/gtk/maketypes.awk
@@ -7,6 +7,8 @@ BEGIN {
gen_macros = 0;
gen_entries = 0;
gen_vars = 0;
+ boxed_copy = "";
+ boxed_free = "";
for (i = 2; i < ARGC; i++)
{
@@ -65,7 +67,7 @@ function set_type (set_type_1)
sub ("^GTK_TYPE_GTK_", "GTK_TYPE_", type_macro);
}
-function generate (generate_1)
+function generate (generate_what)
{
if (gen_macros)
{
@@ -74,10 +76,10 @@ function generate (generate_1)
if (gen_entries)
{
printf (" { \"%s\", &%s,\n", type_name, type_macro);
- if (generate_1 == "BOXED")
- printf (" GTK_TYPE_%s, NULL },\n", generate_1);
+ if (generate_what == "BOXED")
+ printf (" GTK_TYPE_%s, %s, %s, },\n", generate_what, boxed_copy, boxed_free);
else
- printf (" GTK_TYPE_%s, %s_values },\n", generate_1, type_ident);
+ printf (" GTK_TYPE_%s, %s_values },\n", generate_what, type_ident);
}
if (gen_vars)
{
@@ -116,10 +118,31 @@ function generate (generate_1)
if ($2 == "")
printf ("huh? define-boxed keyword without arg?\n") > "/dev/stderr";
else
- {
- set_type($2);
- generate("BOXED");
- }
+ {
+ boxed_copy = "NULL";
+ boxed_free = "NULL";
+ set_type($2);
+ do {
+ getline;
+ sub (";.*", "", $0);
+ } while ($0 ~ /^[ \t]*$/);
+ tmp_var1 = $1;
+ if ($0 ~ /\)/) { generate("BOXED"); next; }
+ do {
+ getline;
+ sub (";.*", "", $0);
+ } while ($0 ~ /^[ \t]*$/);
+ tmp_var2 = $1;
+ sub ("\).*", "", tmp_var2);
+ if (tmp_var1 ~ /^[_A-Za-z][_A-Za-z0-9]*$/ &&
+ tmp_var2 ~ /^[_A-Za-z][_A-Za-z0-9]*$/)
+ {
+ boxed_copy = tmp_var1;
+ boxed_free = tmp_var2;
+ # printf ("read boxed funcs: %s %s\n", boxed_copy, boxed_free) > "/dev/stderr";
+ }
+ generate("BOXED");
+ }
}
END {