summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog16
-rw-r--r--ChangeLog.pre-2-016
-rw-r--r--ChangeLog.pre-2-1016
-rw-r--r--ChangeLog.pre-2-216
-rw-r--r--ChangeLog.pre-2-416
-rw-r--r--ChangeLog.pre-2-616
-rw-r--r--ChangeLog.pre-2-816
-rw-r--r--gdk/gdk.h14
-rw-r--r--gdk/gdkcursor.c13
-rw-r--r--gdk/gdkcursor.h4
-rw-r--r--gdk/x11/gdkcursor-x11.c14
-rw-r--r--gtk/gtkaccellabel.c4
-rw-r--r--gtk/gtkaccellabel.h1
-rw-r--r--gtk/gtkadjustment.h1
-rw-r--r--gtk/gtkalignment.h1
-rw-r--r--gtk/gtkarrow.h1
-rw-r--r--gtk/gtkaspectframe.h2
-rw-r--r--gtk/gtkbbox.h11
-rw-r--r--gtk/gtkbin.h1
-rw-r--r--gtk/gtkbox.h11
-rw-r--r--gtk/gtkbutton.h11
-rw-r--r--gtk/gtkcalendar.h11
-rw-r--r--gtk/gtkcheckbutton.h1
-rw-r--r--gtk/gtkcheckmenuitem.h7
-rw-r--r--gtk/gtkclist.h2
-rw-r--r--gtk/gtkcolorsel.h3
-rw-r--r--gtk/gtkcombo.c8
-rw-r--r--gtk/gtkcombo.h14
-rw-r--r--gtk/gtkcontainer.h7
-rw-r--r--gtk/gtkctree.h1
-rw-r--r--gtk/gtkcurve.h1
-rw-r--r--gtk/gtkdata.h10
-rw-r--r--gtk/gtkdialog.h1
-rw-r--r--gtk/gtkdrawingarea.h1
-rw-r--r--gtk/gtkeditable.h1
-rw-r--r--gtk/gtkentry.h1
-rw-r--r--gtk/gtkeventbox.h11
-rw-r--r--gtk/gtkfilesel.c4
-rw-r--r--gtk/gtkfilesel.h1
-rw-r--r--gtk/gtkfixed.h1
-rw-r--r--gtk/gtkfontsel.h20
-rw-r--r--gtk/gtkframe.h1
-rw-r--r--gtk/gtkgamma.c11
-rw-r--r--gtk/gtkgamma.h12
-rw-r--r--gtk/gtkhandlebox.h1
-rw-r--r--gtk/gtkhbbox.c8
-rw-r--r--gtk/gtkhbbox.h13
-rw-r--r--gtk/gtkhbox.h9
-rw-r--r--gtk/gtkhpaned.c4
-rw-r--r--gtk/gtkhpaned.h9
-rw-r--r--gtk/gtkhruler.c4
-rw-r--r--gtk/gtkhruler.h9
-rw-r--r--gtk/gtkhscale.h2
-rw-r--r--gtk/gtkhscrollbar.h1
-rw-r--r--gtk/gtkhseparator.h1
-rw-r--r--gtk/gtkimage.h1
-rw-r--r--gtk/gtkinputdialog.h1
-rw-r--r--gtk/gtkinvisible.h3
-rw-r--r--gtk/gtkitem.h1
-rw-r--r--gtk/gtkitemfactory.h11
-rw-r--r--gtk/gtklabel.h13
-rw-r--r--gtk/gtklayout.h3
-rw-r--r--gtk/gtklist.h1
-rw-r--r--gtk/gtklistitem.h1
-rw-r--r--gtk/gtkmenu.h1
-rw-r--r--gtk/gtkmenubar.h12
-rw-r--r--gtk/gtkmenuitem.h1
-rw-r--r--gtk/gtkmenushell.h1
-rw-r--r--gtk/gtkmisc.h1
-rw-r--r--gtk/gtknotebook.h2
-rw-r--r--gtk/gtkoptionmenu.h1
-rw-r--r--gtk/gtkpacker.h2
-rw-r--r--gtk/gtkpaned.h1
-rw-r--r--gtk/gtkpixmap.h1
-rw-r--r--gtk/gtkplug.c6
-rw-r--r--gtk/gtkplug.h9
-rw-r--r--gtk/gtkpreview.h1
-rw-r--r--gtk/gtkprogress.h1
-rw-r--r--gtk/gtkprogressbar.h1
-rw-r--r--gtk/gtkradiobutton.h1
-rw-r--r--gtk/gtkradiomenuitem.h1
-rw-r--r--gtk/gtkrange.h1
-rw-r--r--gtk/gtkruler.h2
-rw-r--r--gtk/gtkscale.h1
-rw-r--r--gtk/gtkscrollbar.h1
-rw-r--r--gtk/gtkscrolledwindow.h2
-rw-r--r--gtk/gtkseparator.h2
-rw-r--r--gtk/gtksocket.c20
-rw-r--r--gtk/gtksocket.h11
-rw-r--r--gtk/gtkspinbutton.h1
-rw-r--r--gtk/gtkstatusbar.c6
-rw-r--r--gtk/gtkstatusbar.h11
-rw-r--r--gtk/gtktable.h1
-rw-r--r--gtk/gtktearoffmenuitem.h1
-rw-r--r--gtk/gtktext.h2
-rw-r--r--gtk/gtktipsquery.h1
-rw-r--r--gtk/gtktogglebutton.h1
-rw-r--r--gtk/gtktoolbar.h2
-rw-r--r--gtk/gtktooltips.h3
-rw-r--r--gtk/gtktree.h2
-rw-r--r--gtk/gtktreeitem.h2
-rw-r--r--gtk/gtktypeutils.h1
-rw-r--r--gtk/gtkvbbox.c4
-rw-r--r--gtk/gtkvbbox.h9
-rw-r--r--gtk/gtkvbox.h1
-rw-r--r--gtk/gtkviewport.h1
-rw-r--r--gtk/gtkvpaned.c4
-rw-r--r--gtk/gtkvpaned.h9
-rw-r--r--gtk/gtkvruler.c4
-rw-r--r--gtk/gtkvruler.h9
-rw-r--r--gtk/gtkvscale.h1
-rw-r--r--gtk/gtkvscrollbar.h1
-rw-r--r--gtk/gtkvseparator.h1
-rw-r--r--gtk/gtkwidget.h1
-rw-r--r--gtk/gtkwindow.h9
115 files changed, 424 insertions, 174 deletions
diff --git a/ChangeLog b/ChangeLog
index 4bc366f927..3f0486fef5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,19 @@
+Sun Feb 13 08:54:45 2000 Tim Janik <timj@gtk.org>
+
+ * gdk/gdkcursor.h (struct _GdkCursor): s/refcount/ref_count/.
+ * gdk/x11/gdkcursor-x11.c (gdk_cursor_new_from_pixmap):
+ * gdk/x11/gdkcursor-x11.c (_gdk_cursor_destroy):
+ * gdk/gdkcursor.c (gdk_cursor_ref): insert assertments for the
+ parameters given and cursor->ref_count. coding style fixups.
+
+ * gtk/gtksocket.c (gtk_socket_class_init): parent class is GtkContainer,
+ not GtkWidget.
+
+ * gtk/*.h: applied patch from Mathieu Lacage <lacage@email.enst.fr> to
+ fix up widget macros and add _GET_CLASS() variant.
+
+ * gtk/*.c: some GtkType fixups.
+
2000-02-09 Tor Lillqvist <tml@iki.fi>
* gdk/win32/gdkproperty-win32.c
diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0
index 4bc366f927..3f0486fef5 100644
--- a/ChangeLog.pre-2-0
+++ b/ChangeLog.pre-2-0
@@ -1,3 +1,19 @@
+Sun Feb 13 08:54:45 2000 Tim Janik <timj@gtk.org>
+
+ * gdk/gdkcursor.h (struct _GdkCursor): s/refcount/ref_count/.
+ * gdk/x11/gdkcursor-x11.c (gdk_cursor_new_from_pixmap):
+ * gdk/x11/gdkcursor-x11.c (_gdk_cursor_destroy):
+ * gdk/gdkcursor.c (gdk_cursor_ref): insert assertments for the
+ parameters given and cursor->ref_count. coding style fixups.
+
+ * gtk/gtksocket.c (gtk_socket_class_init): parent class is GtkContainer,
+ not GtkWidget.
+
+ * gtk/*.h: applied patch from Mathieu Lacage <lacage@email.enst.fr> to
+ fix up widget macros and add _GET_CLASS() variant.
+
+ * gtk/*.c: some GtkType fixups.
+
2000-02-09 Tor Lillqvist <tml@iki.fi>
* gdk/win32/gdkproperty-win32.c
diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10
index 4bc366f927..3f0486fef5 100644
--- a/ChangeLog.pre-2-10
+++ b/ChangeLog.pre-2-10
@@ -1,3 +1,19 @@
+Sun Feb 13 08:54:45 2000 Tim Janik <timj@gtk.org>
+
+ * gdk/gdkcursor.h (struct _GdkCursor): s/refcount/ref_count/.
+ * gdk/x11/gdkcursor-x11.c (gdk_cursor_new_from_pixmap):
+ * gdk/x11/gdkcursor-x11.c (_gdk_cursor_destroy):
+ * gdk/gdkcursor.c (gdk_cursor_ref): insert assertments for the
+ parameters given and cursor->ref_count. coding style fixups.
+
+ * gtk/gtksocket.c (gtk_socket_class_init): parent class is GtkContainer,
+ not GtkWidget.
+
+ * gtk/*.h: applied patch from Mathieu Lacage <lacage@email.enst.fr> to
+ fix up widget macros and add _GET_CLASS() variant.
+
+ * gtk/*.c: some GtkType fixups.
+
2000-02-09 Tor Lillqvist <tml@iki.fi>
* gdk/win32/gdkproperty-win32.c
diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2
index 4bc366f927..3f0486fef5 100644
--- a/ChangeLog.pre-2-2
+++ b/ChangeLog.pre-2-2
@@ -1,3 +1,19 @@
+Sun Feb 13 08:54:45 2000 Tim Janik <timj@gtk.org>
+
+ * gdk/gdkcursor.h (struct _GdkCursor): s/refcount/ref_count/.
+ * gdk/x11/gdkcursor-x11.c (gdk_cursor_new_from_pixmap):
+ * gdk/x11/gdkcursor-x11.c (_gdk_cursor_destroy):
+ * gdk/gdkcursor.c (gdk_cursor_ref): insert assertments for the
+ parameters given and cursor->ref_count. coding style fixups.
+
+ * gtk/gtksocket.c (gtk_socket_class_init): parent class is GtkContainer,
+ not GtkWidget.
+
+ * gtk/*.h: applied patch from Mathieu Lacage <lacage@email.enst.fr> to
+ fix up widget macros and add _GET_CLASS() variant.
+
+ * gtk/*.c: some GtkType fixups.
+
2000-02-09 Tor Lillqvist <tml@iki.fi>
* gdk/win32/gdkproperty-win32.c
diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4
index 4bc366f927..3f0486fef5 100644
--- a/ChangeLog.pre-2-4
+++ b/ChangeLog.pre-2-4
@@ -1,3 +1,19 @@
+Sun Feb 13 08:54:45 2000 Tim Janik <timj@gtk.org>
+
+ * gdk/gdkcursor.h (struct _GdkCursor): s/refcount/ref_count/.
+ * gdk/x11/gdkcursor-x11.c (gdk_cursor_new_from_pixmap):
+ * gdk/x11/gdkcursor-x11.c (_gdk_cursor_destroy):
+ * gdk/gdkcursor.c (gdk_cursor_ref): insert assertments for the
+ parameters given and cursor->ref_count. coding style fixups.
+
+ * gtk/gtksocket.c (gtk_socket_class_init): parent class is GtkContainer,
+ not GtkWidget.
+
+ * gtk/*.h: applied patch from Mathieu Lacage <lacage@email.enst.fr> to
+ fix up widget macros and add _GET_CLASS() variant.
+
+ * gtk/*.c: some GtkType fixups.
+
2000-02-09 Tor Lillqvist <tml@iki.fi>
* gdk/win32/gdkproperty-win32.c
diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6
index 4bc366f927..3f0486fef5 100644
--- a/ChangeLog.pre-2-6
+++ b/ChangeLog.pre-2-6
@@ -1,3 +1,19 @@
+Sun Feb 13 08:54:45 2000 Tim Janik <timj@gtk.org>
+
+ * gdk/gdkcursor.h (struct _GdkCursor): s/refcount/ref_count/.
+ * gdk/x11/gdkcursor-x11.c (gdk_cursor_new_from_pixmap):
+ * gdk/x11/gdkcursor-x11.c (_gdk_cursor_destroy):
+ * gdk/gdkcursor.c (gdk_cursor_ref): insert assertments for the
+ parameters given and cursor->ref_count. coding style fixups.
+
+ * gtk/gtksocket.c (gtk_socket_class_init): parent class is GtkContainer,
+ not GtkWidget.
+
+ * gtk/*.h: applied patch from Mathieu Lacage <lacage@email.enst.fr> to
+ fix up widget macros and add _GET_CLASS() variant.
+
+ * gtk/*.c: some GtkType fixups.
+
2000-02-09 Tor Lillqvist <tml@iki.fi>
* gdk/win32/gdkproperty-win32.c
diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8
index 4bc366f927..3f0486fef5 100644
--- a/ChangeLog.pre-2-8
+++ b/ChangeLog.pre-2-8
@@ -1,3 +1,19 @@
+Sun Feb 13 08:54:45 2000 Tim Janik <timj@gtk.org>
+
+ * gdk/gdkcursor.h (struct _GdkCursor): s/refcount/ref_count/.
+ * gdk/x11/gdkcursor-x11.c (gdk_cursor_new_from_pixmap):
+ * gdk/x11/gdkcursor-x11.c (_gdk_cursor_destroy):
+ * gdk/gdkcursor.c (gdk_cursor_ref): insert assertments for the
+ parameters given and cursor->ref_count. coding style fixups.
+
+ * gtk/gtksocket.c (gtk_socket_class_init): parent class is GtkContainer,
+ not GtkWidget.
+
+ * gtk/*.h: applied patch from Mathieu Lacage <lacage@email.enst.fr> to
+ fix up widget macros and add _GET_CLASS() variant.
+
+ * gtk/*.c: some GtkType fixups.
+
2000-02-09 Tor Lillqvist <tml@iki.fi>
* gdk/win32/gdkproperty-win32.c
diff --git a/gdk/gdk.h b/gdk/gdk.h
index 0de20ce523..1a49aa54a7 100644
--- a/gdk/gdk.h
+++ b/gdk/gdk.h
@@ -86,18 +86,18 @@ gint gdk_input_add (gint source,
gpointer data);
void gdk_input_remove (gint tag);
-gint gdk_pointer_grab (GdkWindow * window,
+gint gdk_pointer_grab (GdkWindow *window,
gint owner_events,
GdkEventMask event_mask,
- GdkWindow * confine_to,
- GdkCursor * cursor,
+ GdkWindow *confine_to,
+ GdkCursor *cursor,
guint32 time);
void gdk_pointer_ungrab (guint32 time);
-gint gdk_keyboard_grab (GdkWindow * window,
- gint owner_events,
- guint32 time);
-void gdk_keyboard_ungrab (guint32 time);
+gint gdk_keyboard_grab (GdkWindow *window,
+ gint owner_events,
+ guint32 time);
+void gdk_keyboard_ungrab (guint32 time);
gint gdk_pointer_is_grabbed (void);
diff --git a/gdk/gdkcursor.c b/gdk/gdkcursor.c
index bdea57b5ed..1750fcdc1e 100644
--- a/gdk/gdkcursor.c
+++ b/gdk/gdkcursor.c
@@ -30,7 +30,10 @@
GdkCursor*
gdk_cursor_ref (GdkCursor *cursor)
{
- cursor->refcount += 1;
+ g_return_val_if_fail (cursor != NULL, NULL);
+ g_return_val_if_fail (cursor->ref_count > 0, NULL);
+
+ cursor->ref_count += 1;
return cursor;
}
@@ -39,11 +42,11 @@ void
gdk_cursor_unref (GdkCursor *cursor)
{
g_return_if_fail (cursor != NULL);
- g_return_if_fail (cursor->refcount > 0);
+ g_return_if_fail (cursor->ref_count > 0);
- cursor->refcount -= 1;
+ cursor->ref_count -= 1;
- if (cursor->refcount == 0)
- _gdk_cursor_destroy(cursor);
+ if (cursor->ref_count == 0)
+ _gdk_cursor_destroy (cursor);
}
diff --git a/gdk/gdkcursor.h b/gdk/gdkcursor.h
index fd28ce89f5..56929f2e67 100644
--- a/gdk/gdkcursor.h
+++ b/gdk/gdkcursor.h
@@ -19,12 +19,12 @@ typedef enum
struct _GdkCursor
{
GdkCursorType type;
- guint refcount;
+ guint ref_count;
};
/* Cursors
*/
-GdkCursor* gdk_cursor_new (GdkCursorType cursor_type);
+GdkCursor* gdk_cursor_new (GdkCursorType cursor_type);
GdkCursor* gdk_cursor_new_from_pixmap (GdkPixmap *source,
GdkPixmap *mask,
GdkColor *fg,
diff --git a/gdk/x11/gdkcursor-x11.c b/gdk/x11/gdkcursor-x11.c
index 974135208e..85b5ee56a1 100644
--- a/gdk/x11/gdkcursor-x11.c
+++ b/gdk/x11/gdkcursor-x11.c
@@ -48,14 +48,23 @@ gdk_cursor_new (GdkCursorType cursor_type)
}
GdkCursor*
-gdk_cursor_new_from_pixmap (GdkPixmap *source, GdkPixmap *mask, GdkColor *fg, GdkColor *bg, gint x, gint y)
+gdk_cursor_new_from_pixmap (GdkPixmap *source,
+ GdkPixmap *mask,
+ GdkColor *fg,
+ GdkColor *bg,
+ gint x,
+ gint y)
{
GdkCursorPrivate *private;
GdkCursor *cursor;
Pixmap source_pixmap, mask_pixmap;
Cursor xcursor;
XColor xfg, xbg;
-
+
+ g_return_val_if_fail (source != NULL, NULL);
+ g_return_val_if_fail (fg != NULL, NULL);
+ g_return_val_if_fail (bg != NULL, NULL);
+
source_pixmap = GDK_DRAWABLE_XID (source);
mask_pixmap = GDK_DRAWABLE_XID (mask);
@@ -84,6 +93,7 @@ _gdk_cursor_destroy (GdkCursor *cursor)
GdkCursorPrivate *private;
g_return_if_fail (cursor != NULL);
+ g_return_if_fail (cursor->ref_count == 0);
private = (GdkCursorPrivate *) cursor;
XFreeCursor (private->xdisplay, private->xcursor);
diff --git a/gtk/gtkaccellabel.c b/gtk/gtkaccellabel.c
index 7732ff82af..6861c29875 100644
--- a/gtk/gtkaccellabel.c
+++ b/gtk/gtkaccellabel.c
@@ -78,7 +78,7 @@ gtk_accel_label_get_type (void)
(GtkClassInitFunc) NULL,
};
- accel_label_type = gtk_type_unique (gtk_label_get_type (), &accel_label_info);
+ accel_label_type = gtk_type_unique (GTK_TYPE_LABEL, &accel_label_info);
}
return accel_label_type;
@@ -98,7 +98,7 @@ gtk_accel_label_class_init (GtkAccelLabelClass *class)
misc_class = (GtkMiscClass*) class;
label_class = (GtkLabelClass*) class;
- parent_class = gtk_type_class (gtk_label_get_type ());
+ parent_class = gtk_type_class (GTK_TYPE_LABEL);
gtk_object_add_arg_type ("GtkAccelLabel::accel_widget", GTK_TYPE_WIDGET, GTK_ARG_READWRITE, ARG_ACCEL_WIDGET);
diff --git a/gtk/gtkaccellabel.h b/gtk/gtkaccellabel.h
index 59db3ad98c..59626f2043 100644
--- a/gtk/gtkaccellabel.h
+++ b/gtk/gtkaccellabel.h
@@ -44,6 +44,7 @@ extern "C" {
#define GTK_ACCEL_LABEL_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_ACCEL_LABEL, GtkAccelLabelClass))
#define GTK_IS_ACCEL_LABEL(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_ACCEL_LABEL))
#define GTK_IS_ACCEL_LABEL_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_ACCEL_LABEL))
+#define GTK_ACCEL_LABEL_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_ACCEL_LABEL, GtkAccelLabelClass))
typedef struct _GtkAccelLabel GtkAccelLabel;
diff --git a/gtk/gtkadjustment.h b/gtk/gtkadjustment.h
index 71e6bddfad..10ad62c966 100644
--- a/gtk/gtkadjustment.h
+++ b/gtk/gtkadjustment.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_ADJUSTMENT_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_ADJUSTMENT, GtkAdjustmentClass))
#define GTK_IS_ADJUSTMENT(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_ADJUSTMENT))
#define GTK_IS_ADJUSTMENT_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_ADJUSTMENT))
+#define GTK_ADJUSTMENT_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_ADJUSTMENT, GtkAdjustmentClass))
typedef struct _GtkAdjustment GtkAdjustment;
diff --git a/gtk/gtkalignment.h b/gtk/gtkalignment.h
index a99a7e7747..b84dd04e1f 100644
--- a/gtk/gtkalignment.h
+++ b/gtk/gtkalignment.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_ALIGNMENT_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_ALIGNMENT, GtkAlignmentClass))
#define GTK_IS_ALIGNMENT(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_ALIGNMENT))
#define GTK_IS_ALIGNMENT_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_ALIGNMENT))
+#define GTK_ALIGNMENT_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_ALIGNMENT, GtkAlignmentClass))
typedef struct _GtkAlignment GtkAlignment;
diff --git a/gtk/gtkarrow.h b/gtk/gtkarrow.h
index 1793fefde1..cd4dfd0fe9 100644
--- a/gtk/gtkarrow.h
+++ b/gtk/gtkarrow.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_ARROW_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_ARROW, GtkArrowClass))
#define GTK_IS_ARROW(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_ARROW))
#define GTK_IS_ARROW_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_ARROW))
+#define GTK_ARROW_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_ARROW, GtkArrowClass))
typedef struct _GtkArrow GtkArrow;
diff --git a/gtk/gtkaspectframe.h b/gtk/gtkaspectframe.h
index 6f757236c7..f9d34937d4 100644
--- a/gtk/gtkaspectframe.h
+++ b/gtk/gtkaspectframe.h
@@ -42,7 +42,7 @@ extern "C" {
#define GTK_ASPECT_FRAME_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_ASPECT_FRAME, GtkAspectFrameClass))
#define GTK_IS_ASPECT_FRAME(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_ASPECT_FRAME))
#define GTK_IS_ASPECT_FRAME_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_ASPECT_FRAME))
-
+#define GTK_ASPECT_FRAME_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_ASPECT_FRAME, GtkAspectFrameClass))
typedef struct _GtkAspectFrame GtkAspectFrame;
diff --git a/gtk/gtkbbox.h b/gtk/gtkbbox.h
index d870d9043c..e46f98ca8a 100644
--- a/gtk/gtkbbox.h
+++ b/gtk/gtkbbox.h
@@ -35,11 +35,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_TYPE_BUTTON_BOX (gtk_button_box_get_type ())
-#define GTK_BUTTON_BOX(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_BUTTON_BOX, GtkButtonBox))
-#define GTK_BUTTON_BOX_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_BUTTON_BOX, GtkButtonBoxClass))
-#define GTK_IS_BUTTON_BOX(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_BUTTON_BOX))
-#define GTK_IS_BUTTON_BOX_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_BUTTON_BOX))
+#define GTK_TYPE_BUTTON_BOX (gtk_button_box_get_type ())
+#define GTK_BUTTON_BOX(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_BUTTON_BOX, GtkButtonBox))
+#define GTK_BUTTON_BOX_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_BUTTON_BOX, GtkButtonBoxClass))
+#define GTK_IS_BUTTON_BOX(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_BUTTON_BOX))
+#define GTK_IS_BUTTON_BOX_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_BUTTON_BOX))
+#define GTK_BUTTON_BOX_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_BUTTON_BOX, GtkButtonBoxClass))
#define GTK_BUTTONBOX_DEFAULT -1
diff --git a/gtk/gtkbin.h b/gtk/gtkbin.h
index d81d09650e..854f20235f 100644
--- a/gtk/gtkbin.h
+++ b/gtk/gtkbin.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_BIN_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_BIN, GtkBinClass))
#define GTK_IS_BIN(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_BIN))
#define GTK_IS_BIN_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_BIN))
+#define GTK_BIN_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_BIN, GtkBinClass))
typedef struct _GtkBin GtkBin;
diff --git a/gtk/gtkbox.h b/gtk/gtkbox.h
index 7e9bec260a..6f41d004f5 100644
--- a/gtk/gtkbox.h
+++ b/gtk/gtkbox.h
@@ -37,11 +37,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_TYPE_BOX (gtk_box_get_type ())
-#define GTK_BOX(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_BOX, GtkBox))
-#define GTK_BOX_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_BOX, GtkBoxClass))
-#define GTK_IS_BOX(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_BOX))
-#define GTK_IS_BOX_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_BOX))
+#define GTK_TYPE_BOX (gtk_box_get_type ())
+#define GTK_BOX(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_BOX, GtkBox))
+#define GTK_BOX_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_BOX, GtkBoxClass))
+#define GTK_IS_BOX(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_BOX))
+#define GTK_IS_BOX_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_BOX))
+#define GTK_BOX_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_BOX, GtkBoxClass))
typedef struct _GtkBox GtkBox;
diff --git a/gtk/gtkbutton.h b/gtk/gtkbutton.h
index cf8054fb03..9af90ea1ec 100644
--- a/gtk/gtkbutton.h
+++ b/gtk/gtkbutton.h
@@ -37,11 +37,12 @@
extern "C" {
#endif /* __cplusplus */
-#define GTK_TYPE_BUTTON (gtk_button_get_type ())
-#define GTK_BUTTON(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_BUTTON, GtkButton))
-#define GTK_BUTTON_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_BUTTON, GtkButtonClass))
-#define GTK_IS_BUTTON(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_BUTTON))
-#define GTK_IS_BUTTON_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_BUTTON))
+#define GTK_TYPE_BUTTON (gtk_button_get_type ())
+#define GTK_BUTTON(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_BUTTON, GtkButton))
+#define GTK_BUTTON_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_BUTTON, GtkButtonClass))
+#define GTK_IS_BUTTON(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_BUTTON))
+#define GTK_IS_BUTTON_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_BUTTON))
+#define GTK_BUTTON_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_BUTTON, GtkButtonClass))
typedef struct _GtkButton GtkButton;
diff --git a/gtk/gtkcalendar.h b/gtk/gtkcalendar.h
index f7e6f50c99..19775c70fd 100644
--- a/gtk/gtkcalendar.h
+++ b/gtk/gtkcalendar.h
@@ -39,11 +39,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_TYPE_CALENDAR (gtk_calendar_get_type ())
-#define GTK_CALENDAR(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_CALENDAR, GtkCalendar))
-#define GTK_CALENDAR_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_CALENDAR, GtkCalendarClass))
-#define GTK_IS_CALENDAR(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_CALENDAR))
-#define GTK_IS_CALENDAR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_CALENDAR))
+#define GTK_TYPE_CALENDAR (gtk_calendar_get_type ())
+#define GTK_CALENDAR(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_CALENDAR, GtkCalendar))
+#define GTK_CALENDAR_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_CALENDAR, GtkCalendarClass))
+#define GTK_IS_CALENDAR(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_CALENDAR))
+#define GTK_IS_CALENDAR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_CALENDAR))
+#define GTK_CALENDAR_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_CALENDAR, GtkCalendarClass))
typedef struct _GtkCalendar GtkCalendar;
diff --git a/gtk/gtkcheckbutton.h b/gtk/gtkcheckbutton.h
index 5ba1ac87aa..c76a1ff205 100644
--- a/gtk/gtkcheckbutton.h
+++ b/gtk/gtkcheckbutton.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_CHECK_BUTTON_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_CHECK_BUTTON, GtkCheckButtonClass))
#define GTK_IS_CHECK_BUTTON(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_CHECK_BUTTON))
#define GTK_IS_CHECK_BUTTON_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_CHECK_BUTTON))
+#define GTK_CHECK_BUTTON_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_CHECK_BUTTON, GtkCheckButtonClass))
typedef struct _GtkCheckButton GtkCheckButton;
diff --git a/gtk/gtkcheckmenuitem.h b/gtk/gtkcheckmenuitem.h
index 84d515d304..22d3681cfd 100644
--- a/gtk/gtkcheckmenuitem.h
+++ b/gtk/gtkcheckmenuitem.h
@@ -37,11 +37,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_TYPE_CHECK_MENU_ITEM (gtk_check_menu_item_get_type ())
-#define GTK_CHECK_MENU_ITEM(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_CHECK_MENU_ITEM, GtkCheckMenuItem))
+#define GTK_TYPE_CHECK_MENU_ITEM (gtk_check_menu_item_get_type ())
+#define GTK_CHECK_MENU_ITEM(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_CHECK_MENU_ITEM, GtkCheckMenuItem))
#define GTK_CHECK_MENU_ITEM_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_CHECK_MENU_ITEM, GtkCheckMenuItemClass))
-#define GTK_IS_CHECK_MENU_ITEM(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_CHECK_MENU_ITEM))
+#define GTK_IS_CHECK_MENU_ITEM(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_CHECK_MENU_ITEM))
#define GTK_IS_CHECK_MENU_ITEM_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_CHECK_MENU_ITEM))
+#define GTK_CHECK_MENU_ITEM_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_CHECK_MENU_ITEM, GtkCheckMenuItemClass))
typedef struct _GtkCheckMenuItem GtkCheckMenuItem;
diff --git a/gtk/gtkclist.h b/gtk/gtkclist.h
index 5c02eeeee1..d1eb664788 100644
--- a/gtk/gtkclist.h
+++ b/gtk/gtkclist.h
@@ -87,6 +87,8 @@ typedef enum
#define GTK_CLIST_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_CLIST, GtkCListClass))
#define GTK_IS_CLIST(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_CLIST))
#define GTK_IS_CLIST_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_CLIST))
+#define GTK_CLIST_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_CLIST, GtkCListClass))
+
#define GTK_CLIST_FLAGS(clist) (GTK_CLIST (clist)->flags)
#define GTK_CLIST_SET_FLAG(clist,flag) (GTK_CLIST_FLAGS (clist) |= (GTK_ ## flag))
diff --git a/gtk/gtkcolorsel.h b/gtk/gtkcolorsel.h
index fff80d3878..14e622e7d1 100644
--- a/gtk/gtkcolorsel.h
+++ b/gtk/gtkcolorsel.h
@@ -55,12 +55,15 @@ extern "C" {
#define GTK_COLOR_SELECTION_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_COLOR_SELECTION, GtkColorSelectionClass))
#define GTK_IS_COLOR_SELECTION(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_COLOR_SELECTION))
#define GTK_IS_COLOR_SELECTION_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_COLOR_SELECTION))
+#define GTK_COLOR_SELECTION_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_COLOR_SELECTION, GtkColorSelectionClass))
+
#define GTK_TYPE_COLOR_SELECTION_DIALOG (gtk_color_selection_dialog_get_type ())
#define GTK_COLOR_SELECTION_DIALOG(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_COLOR_SELECTION_DIALOG, GtkColorSelectionDialog))
#define GTK_COLOR_SELECTION_DIALOG_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_COLOR_SELECTION_DIALOG, GtkColorSelectionDialogClass))
#define GTK_IS_COLOR_SELECTION_DIALOG(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_COLOR_SELECTION_DIALOG))
#define GTK_IS_COLOR_SELECTION_DIALOG_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_COLOR_SELECTION_DIALOG))
+#define GTK_COLOR_SELECTION_DIALOG_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_COLOR_SELECTION_DIALOG, GtkColorSelectionDialogClass))
typedef struct _GtkColorSelection GtkColorSelection;
typedef struct _GtkColorSelectionClass GtkColorSelectionClass;
diff --git a/gtk/gtkcombo.c b/gtk/gtkcombo.c
index aabc5da141..33cb37669c 100644
--- a/gtk/gtkcombo.c
+++ b/gtk/gtkcombo.c
@@ -100,7 +100,7 @@ gtk_combo_class_init (GtkComboClass * klass)
GtkObjectClass *oclass;
GtkWidgetClass *widget_class;
- parent_class = gtk_type_class (gtk_hbox_get_type ());
+ parent_class = gtk_type_class (GTK_TYPE_HBOX);
oclass = (GtkObjectClass *) klass;
widget_class = (GtkWidgetClass *) klass;
@@ -757,15 +757,15 @@ gtk_combo_get_type (void)
/* reserved_2 */ NULL,
(GtkClassInitFunc) NULL,
};
- combo_type = gtk_type_unique (gtk_hbox_get_type (), &combo_info);
+ combo_type = gtk_type_unique (GTK_TYPE_HBOX, &combo_info);
}
return combo_type;
}
-GtkWidget *
+GtkWidget*
gtk_combo_new (void)
{
- return GTK_WIDGET (gtk_type_new (gtk_combo_get_type ()));
+ return GTK_WIDGET (gtk_type_new (GTK_TYPE_COMBO));
}
void
diff --git a/gtk/gtkcombo.h b/gtk/gtkcombo.h
index 468116517c..919f77cbf2 100644
--- a/gtk/gtkcombo.h
+++ b/gtk/gtkcombo.h
@@ -34,11 +34,15 @@
extern "C" {
#endif /* __cplusplus */
-#define GTK_COMBO(obj) GTK_CHECK_CAST (obj, gtk_combo_get_type (), GtkCombo)
-#define GTK_COMBO_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_combo_get_type (), GtkComboClass)
-#define GTK_IS_COMBO(obj) GTK_CHECK_TYPE (obj, gtk_combo_get_type ())
+#define GTK_TYPE_COMBO (gtk_combo_get_type ())
+#define GTK_COMBO(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_COMBO, GtkCombo))
+#define GTK_COMBO_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_COMBO, GtkComboClass))
+#define GTK_IS_COMBO(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_COMBO))
+#define GTK_IS_COMBO_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_COMBO))
+#define GTK_COMBO_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_COMBO, GtkComboClass))
-typedef struct _GtkCombo GtkCombo;
+
+typedef struct _GtkCombo GtkCombo;
typedef struct _GtkComboClass GtkComboClass;
/* you should access only the entry and list fields directly */
@@ -69,7 +73,7 @@ struct _GtkComboClass {
GtkType gtk_combo_get_type (void);
-GtkWidget *gtk_combo_new (void);
+GtkWidget* gtk_combo_new (void);
/* the text in the entry must be or not be in the list */
void gtk_combo_set_value_in_list (GtkCombo* combo,
gint val,
diff --git a/gtk/gtkcontainer.h b/gtk/gtkcontainer.h
index 6cfe9b8f50..f3e1de3586 100644
--- a/gtk/gtkcontainer.h
+++ b/gtk/gtkcontainer.h
@@ -39,11 +39,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_TYPE_CONTAINER (gtk_container_get_type ())
-#define GTK_CONTAINER(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_CONTAINER, GtkContainer))
+#define GTK_TYPE_CONTAINER (gtk_container_get_type ())
+#define GTK_CONTAINER(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_CONTAINER, GtkContainer))
#define GTK_CONTAINER_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_CONTAINER, GtkContainerClass))
-#define GTK_IS_CONTAINER(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_CONTAINER))
+#define GTK_IS_CONTAINER(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_CONTAINER))
#define GTK_IS_CONTAINER_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_CONTAINER))
+#define GTK_CONTAINER_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_CONTAINER, GtkContainerClass))
#define GTK_IS_RESIZE_CONTAINER(widget) (GTK_IS_CONTAINER (widget) && ((GtkContainer*) (widget))->resize_mode != GTK_RESIZE_PARENT)
diff --git a/gtk/gtkctree.h b/gtk/gtkctree.h
index 487ff2f3e8..1b67491c2c 100644
--- a/gtk/gtkctree.h
+++ b/gtk/gtkctree.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_CTREE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_CTREE, GtkCTreeClass))
#define GTK_IS_CTREE(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_CTREE))
#define GTK_IS_CTREE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_CTREE))
+#define GTK_CTREE_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_CTREE, GtkCTreeClass))
#define GTK_CTREE_ROW(_node_) ((GtkCTreeRow *)(((GList *)(_node_))->data))
#define GTK_CTREE_NODE(_node_) ((GtkCTreeNode *)((_node_)))
diff --git a/gtk/gtkcurve.h b/gtk/gtkcurve.h
index 47e69bb1ad..84f6d4f90f 100644
--- a/gtk/gtkcurve.h
+++ b/gtk/gtkcurve.h
@@ -41,6 +41,7 @@ extern "C" {
#define GTK_CURVE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_CURVE, GtkCurveClass))
#define GTK_IS_CURVE(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_CURVE))
#define GTK_IS_CURVE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_CURVE))
+#define GTK_CURVE_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_CURVE, GtkCurveClass))
typedef struct _GtkCurve GtkCurve;
diff --git a/gtk/gtkdata.h b/gtk/gtkdata.h
index 7ff690ad26..ddc8fc8dab 100644
--- a/gtk/gtkdata.h
+++ b/gtk/gtkdata.h
@@ -37,12 +37,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_TYPE_DATA (gtk_data_get_type ())
-#define GTK_DATA(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_DATA, GtkData))
-#define GTK_DATA_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_DATA, GtkDataClass))
-#define GTK_IS_DATA(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_DATA))
+#define GTK_TYPE_DATA (gtk_data_get_type ())
+#define GTK_DATA(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_DATA, GtkData))
+#define GTK_DATA_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_DATA, GtkDataClass))
+#define GTK_IS_DATA(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_DATA))
#define GTK_IS_DATA_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_DATA))
-
+#define GTK_DATA_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_DATA, GtkDataClass))
typedef struct _GtkData GtkData;
diff --git a/gtk/gtkdialog.h b/gtk/gtkdialog.h
index bece9e16ea..f3820945bf 100644
--- a/gtk/gtkdialog.h
+++ b/gtk/gtkdialog.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_DIALOG_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_DIALOG, GtkDialogClass))
#define GTK_IS_DIALOG(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_DIALOG))
#define GTK_IS_DIALOG_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_DIALOG))
+#define GTK_DIALOG_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_DIALOG, GtkDialogClass))
typedef struct _GtkDialog GtkDialog;
diff --git a/gtk/gtkdrawingarea.h b/gtk/gtkdrawingarea.h
index bad9b7b1f3..07625ad470 100644
--- a/gtk/gtkdrawingarea.h
+++ b/gtk/gtkdrawingarea.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_DRAWING_AREA_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_DRAWING_AREA, GtkDrawingAreaClass))
#define GTK_IS_DRAWING_AREA(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_DRAWING_AREA))
#define GTK_IS_DRAWING_AREA_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_DRAWING_AREA))
+#define GTK_DRAWING_AREA_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_DRAWING_AREA, GtkDrawingAreaClass))
typedef struct _GtkDrawingArea GtkDrawingArea;
diff --git a/gtk/gtkeditable.h b/gtk/gtkeditable.h
index 5ff0ecbb5b..67982fb8a2 100644
--- a/gtk/gtkeditable.h
+++ b/gtk/gtkeditable.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_EDITABLE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_EDITABLE, GtkEditableClass))
#define GTK_IS_EDITABLE(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_EDITABLE))
#define GTK_IS_EDITABLE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_EDITABLE))
+#define GTK_EDITABLE_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_EDITABLE, GtkEditableClass))
typedef struct _GtkEditable GtkEditable;
diff --git a/gtk/gtkentry.h b/gtk/gtkentry.h
index cff49bd0a2..7ef9f158df 100644
--- a/gtk/gtkentry.h
+++ b/gtk/gtkentry.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_ENTRY_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_ENTRY, GtkEntryClass))
#define GTK_IS_ENTRY(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_ENTRY))
#define GTK_IS_ENTRY_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_ENTRY))
+#define GTK_ENTRY_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_ENTRY, GtkEntryClass))
typedef struct _GtkEntry GtkEntry;
diff --git a/gtk/gtkeventbox.h b/gtk/gtkeventbox.h
index 1d89793ee5..189d1a0eea 100644
--- a/gtk/gtkeventbox.h
+++ b/gtk/gtkeventbox.h
@@ -37,11 +37,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_TYPE_EVENT_BOX (gtk_event_box_get_type ())
-#define GTK_EVENT_BOX(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_EVENT_BOX, GtkEventBox))
-#define GTK_EVENT_BOX_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_EVENT_BOX, GtkEventBoxClass))
-#define GTK_IS_EVENT_BOX(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_EVENT_BOX))
-#define GTK_IS_EVENT_BOX_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_EVENT_BOX))
+#define GTK_TYPE_EVENT_BOX (gtk_event_box_get_type ())
+#define GTK_EVENT_BOX(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_EVENT_BOX, GtkEventBox))
+#define GTK_EVENT_BOX_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_EVENT_BOX, GtkEventBoxClass))
+#define GTK_IS_EVENT_BOX(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_EVENT_BOX))
+#define GTK_IS_EVENT_BOX_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_EVENT_BOX))
+#define GTK_EVENT_BOX_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_EVENT_BOX, GtkEventBoxClass))
typedef struct _GtkEventBox GtkEventBox;
diff --git a/gtk/gtkfilesel.c b/gtk/gtkfilesel.c
index e792948640..2f41642f69 100644
--- a/gtk/gtkfilesel.c
+++ b/gtk/gtkfilesel.c
@@ -2123,14 +2123,12 @@ open_new_dir(gchar* dir_name, struct stat* sbuf, gboolean stat_subdirs)
{
CompletionDirSent* sent;
DIR* directory;
- gchar *buffer_ptr;
struct dirent *dirent_ptr;
gint entry_count = 0;
gint i;
struct stat ent_sbuf;
GString *path;
- gchar *xdir, *xname;
- int entry_len;
+ gchar *xdir;
sent = g_new(CompletionDirSent, 1);
sent->mtime = sbuf->st_mtime;
diff --git a/gtk/gtkfilesel.h b/gtk/gtkfilesel.h
index d5970c3f1a..5db69f84ec 100644
--- a/gtk/gtkfilesel.h
+++ b/gtk/gtkfilesel.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_FILE_SELECTION_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_FILE_SELECTION, GtkFileSelectionClass))
#define GTK_IS_FILE_SELECTION(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_FILE_SELECTION))
#define GTK_IS_FILE_SELECTION_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_FILE_SELECTION))
+#define GTK_FILE_SELECTION_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_FILE_SELECTION, GtkFileSelectionClass))
typedef struct _GtkFileSelection GtkFileSelection;
diff --git a/gtk/gtkfixed.h b/gtk/gtkfixed.h
index 27a06c3d5f..13dd8e97a2 100644
--- a/gtk/gtkfixed.h
+++ b/gtk/gtkfixed.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_FIXED_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_FIXED, GtkFixedClass))
#define GTK_IS_FIXED(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_FIXED))
#define GTK_IS_FIXED_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_FIXED))
+#define GTK_FIXED_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_FIXED, GtkFixedClass))
typedef struct _GtkFixed GtkFixed;
diff --git a/gtk/gtkfontsel.h b/gtk/gtkfontsel.h
index a9aea39ec4..fbd3ac3a5e 100644
--- a/gtk/gtkfontsel.h
+++ b/gtk/gtkfontsel.h
@@ -41,17 +41,21 @@
extern "C" {
#endif /* __cplusplus */
-#define GTK_TYPE_FONT_SELECTION (gtk_font_selection_get_type ())
-#define GTK_FONT_SELECTION(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_FONT_SELECTION, GtkFontSelection))
-#define GTK_FONT_SELECTION_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_FONT_SELECTION, GtkFontSelectionClass))
-#define GTK_IS_FONT_SELECTION(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_FONT_SELECTION))
+#define GTK_TYPE_FONT_SELECTION (gtk_font_selection_get_type ())
+#define GTK_FONT_SELECTION(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_FONT_SELECTION, GtkFontSelection))
+#define GTK_FONT_SELECTION_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_FONT_SELECTION, GtkFontSelectionClass))
+#define GTK_IS_FONT_SELECTION(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_FONT_SELECTION))
#define GTK_IS_FONT_SELECTION_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_FONT_SELECTION))
+#define GTK_FONT_SELECTION_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_FONT_SELECTION, GtkFontSelectionClass))
-#define GTK_TYPE_FONT_SELECTION_DIALOG (gtk_font_selection_dialog_get_type ())
-#define GTK_FONT_SELECTION_DIALOG(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_FONT_SELECTION_DIALOG, GtkFontSelectionDialog))
-#define GTK_FONT_SELECTION_DIALOG_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_FONT_SELECTION_DIALOG, GtkFontSelectionDialogClass))
-#define GTK_IS_FONT_SELECTION_DIALOG(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_FONT_SELECTION_DIALOG))
+
+#define GTK_TYPE_FONT_SELECTION_DIALOG (gtk_font_selection_dialog_get_type ())
+#define GTK_FONT_SELECTION_DIALOG(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_FONT_SELECTION_DIALOG, GtkFontSelectionDialog))
+#define GTK_FONT_SELECTION_DIALOG_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_FONT_SELECTION_DIALOG, GtkFontSelectionDialogClass))
+#define GTK_IS_FONT_SELECTION_DIALOG(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_FONT_SELECTION_DIALOG))
#define GTK_IS_FONT_SELECTION_DIALOG_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_FONT_SELECTION_DIALOG))
+#define GTK_FONT_SELECTION_DIALOG_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_FONT_SELECTION_DIALOG, GtkFontSelectionDialogClass))
+
typedef struct _GtkFontSelection GtkFontSelection;
typedef struct _GtkFontSelectionClass GtkFontSelectionClass;
diff --git a/gtk/gtkframe.h b/gtk/gtkframe.h
index 269b080b7d..7e6dc56dd1 100644
--- a/gtk/gtkframe.h
+++ b/gtk/gtkframe.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_FRAME_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_FRAME, GtkFrameClass))
#define GTK_IS_FRAME(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_FRAME))
#define GTK_IS_FRAME_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_FRAME))
+#define GTK_FRAME_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_FRAME, GtkFrameClass))
typedef struct _GtkFrame GtkFrame;
diff --git a/gtk/gtkgamma.c b/gtk/gtkgamma.c
index 3d8b3bd381..108a9ffd4e 100644
--- a/gtk/gtkgamma.c
+++ b/gtk/gtkgamma.c
@@ -215,7 +215,7 @@ GtkType
gtk_gamma_curve_get_type (void)
{
static GtkType gamma_curve_type = 0;
-
+
if (!gamma_curve_type)
{
static const GtkTypeInfo gamma_curve_info =
@@ -229,9 +229,8 @@ gtk_gamma_curve_get_type (void)
/* reserved_2 */ NULL,
(GtkClassInitFunc) NULL,
};
-
- gamma_curve_type =
- gtk_type_unique (gtk_vbox_get_type (), &gamma_curve_info);
+
+ gamma_curve_type = gtk_type_unique (GTK_TYPE_VBOX, &gamma_curve_info);
}
return gamma_curve_type;
}
@@ -241,7 +240,7 @@ gtk_gamma_curve_class_init (GtkGammaCurveClass *class)
{
GtkObjectClass *object_class;
- parent_class = gtk_type_class (gtk_vbox_get_type ());
+ parent_class = gtk_type_class (GTK_TYPE_VBOX);
object_class = (GtkObjectClass *) class;
object_class->destroy = gtk_gamma_curve_destroy;
@@ -458,7 +457,7 @@ curve_type_changed_callback (GtkWidget *w, gpointer data)
GtkWidget*
gtk_gamma_curve_new (void)
{
- return gtk_type_new (gtk_gamma_curve_get_type ());
+ return gtk_type_new (GTK_TYPE_GAMMA_CURVE);
}
static void
diff --git a/gtk/gtkgamma.h b/gtk/gtkgamma.h
index eea6855ab8..302dc8c11a 100644
--- a/gtk/gtkgamma.h
+++ b/gtk/gtkgamma.h
@@ -37,12 +37,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_TYPE_GAMMA_CURVE (gtk_gamma_curve_get_type ())
-#define GTK_GAMMA_CURVE(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_GAMMA_CURVE, GtkGammaCurve))
-#define GTK_GAMMA_CURVE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_GAMMA_CURVE, GtkGammaCurveClass))
-#define GTK_IS_GAMMA_CURVE(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_GAMMA_CURVE))
-#define GTK_IS_GAMMA_CURVE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_GAMMA_CURVE))
-
+#define GTK_TYPE_GAMMA_CURVE (gtk_gamma_curve_get_type ())
+#define GTK_GAMMA_CURVE(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_GAMMA_CURVE, GtkGammaCurve))
+#define GTK_GAMMA_CURVE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_GAMMA_CURVE, GtkGammaCurveClass))
+#define GTK_IS_GAMMA_CURVE(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_GAMMA_CURVE))
+#define GTK_IS_GAMMA_CURVE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_GAMMA_CURVE))
+#define GTK_GAMMA_CURVE_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_GAMMA_CURVE, GtkGammaCurveClass))
typedef struct _GtkGammaCurve GtkGammaCurve;
typedef struct _GtkGammaCurveClass GtkGammaCurveClass;
diff --git a/gtk/gtkhandlebox.h b/gtk/gtkhandlebox.h
index f49dcf5805..0eceef4338 100644
--- a/gtk/gtkhandlebox.h
+++ b/gtk/gtkhandlebox.h
@@ -48,6 +48,7 @@ extern "C" {
#define GTK_HANDLE_BOX_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_HANDLE_BOX, GtkHandleBoxClass))
#define GTK_IS_HANDLE_BOX(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_HANDLE_BOX))
#define GTK_IS_HANDLE_BOX_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_HANDLE_BOX))
+#define GTK_HANDLE_BOX_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_HANDLE_BOX, GtkHandleBoxClass))
typedef struct _GtkHandleBox GtkHandleBox;
diff --git a/gtk/gtkhbbox.c b/gtk/gtkhbbox.c
index 9cfb89dcf1..8ba84d7089 100644
--- a/gtk/gtkhbbox.c
+++ b/gtk/gtkhbbox.c
@@ -37,10 +37,10 @@ static void gtk_hbutton_box_size_allocate (GtkWidget *widget,
static gint default_spacing = 30;
static gint default_layout_style = GTK_BUTTONBOX_EDGE;
-guint
+GtkType
gtk_hbutton_box_get_type (void)
{
- static guint hbutton_box_type = 0;
+ static GtkType hbutton_box_type = 0;
if (!hbutton_box_type)
{
@@ -56,7 +56,7 @@ gtk_hbutton_box_get_type (void)
(GtkClassInitFunc) NULL,
};
- hbutton_box_type = gtk_type_unique (gtk_button_box_get_type (), &hbutton_box_info);
+ hbutton_box_type = gtk_type_unique (GTK_TYPE_BUTTON_BOX, &hbutton_box_info);
}
return hbutton_box_type;
@@ -84,7 +84,7 @@ gtk_hbutton_box_new (void)
{
GtkHButtonBox *hbutton_box;
- hbutton_box = gtk_type_new (gtk_hbutton_box_get_type ());
+ hbutton_box = gtk_type_new (GTK_TYPE_HBUTTON_BOX);
return GTK_WIDGET (hbutton_box);
}
diff --git a/gtk/gtkhbbox.h b/gtk/gtkhbbox.h
index 74b86f824f..38d2e9055c 100644
--- a/gtk/gtkhbbox.h
+++ b/gtk/gtkhbbox.h
@@ -36,9 +36,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_HBUTTON_BOX(obj) GTK_CHECK_CAST (obj, gtk_hbutton_box_get_type (), GtkHButtonBox)
-#define GTK_HBUTTON_BOX_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_hbutton_box_get_type (), GtkHButtonBoxClass)
-#define GTK_IS_HBUTTON_BOX(obj) GTK_CHECK_TYPE (obj, gtk_hbutton_box_get_type ())
+#define GTK_TYPE_HBUTTON_BOX (gtk_hbutton_box_get_type ())
+#define GTK_HBUTTON_BOX(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_HBUTTON_BOX, GtkHButtonBox))
+#define GTK_HBUTTON_BOX_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_HBUTTON_BOX, GtkHButtonBoxClass))
+#define GTK_IS_HBUTTON_BOX(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_HBUTTON_BOX))
+#define GTK_IS_HBUTTON_BOX_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_HBUTTON_BOX))
+#define GTK_HBUTTON_BOX_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_HBUTTON_BOX, GtkHButtonBoxClass))
typedef struct _GtkHButtonBox GtkHButtonBox;
@@ -55,8 +58,8 @@ struct _GtkHButtonBoxClass
};
-guint gtk_hbutton_box_get_type (void);
-GtkWidget *gtk_hbutton_box_new (void);
+GtkType gtk_hbutton_box_get_type (void);
+GtkWidget* gtk_hbutton_box_new (void);
/* buttons can be added by gtk_container_add() */
diff --git a/gtk/gtkhbox.h b/gtk/gtkhbox.h
index 59567ce522..f4c3c9eb4d 100644
--- a/gtk/gtkhbox.h
+++ b/gtk/gtkhbox.h
@@ -37,11 +37,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_TYPE_HBOX (gtk_hbox_get_type ())
-#define GTK_HBOX(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_HBOX, GtkHBox))
-#define GTK_HBOX_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_HBOX, GtkHBoxClass))
-#define GTK_IS_HBOX(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_HBOX))
+#define GTK_TYPE_HBOX (gtk_hbox_get_type ())
+#define GTK_HBOX(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_HBOX, GtkHBox))
+#define GTK_HBOX_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_HBOX, GtkHBoxClass))
+#define GTK_IS_HBOX(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_HBOX))
#define GTK_IS_HBOX_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_HBOX))
+#define GTK_HBOX_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_HBOX, GtkHBoxClass))
typedef struct _GtkHBox GtkHBox;
diff --git a/gtk/gtkhpaned.c b/gtk/gtkhpaned.c
index 7fa7b4e37f..a561288055 100644
--- a/gtk/gtkhpaned.c
+++ b/gtk/gtkhpaned.c
@@ -63,7 +63,7 @@ gtk_hpaned_get_type (void)
(GtkClassInitFunc) NULL,
};
- hpaned_type = gtk_type_unique (gtk_paned_get_type (), &hpaned_info);
+ hpaned_type = gtk_type_unique (GTK_TYPE_PANED, &hpaned_info);
}
return hpaned_type;
@@ -94,7 +94,7 @@ gtk_hpaned_new (void)
{
GtkHPaned *hpaned;
- hpaned = gtk_type_new (gtk_hpaned_get_type ());
+ hpaned = gtk_type_new (GTK_TYPE_HPANED);
return GTK_WIDGET (hpaned);
}
diff --git a/gtk/gtkhpaned.h b/gtk/gtkhpaned.h
index 460022f59f..2b3e3b0969 100644
--- a/gtk/gtkhpaned.h
+++ b/gtk/gtkhpaned.h
@@ -37,9 +37,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_HPANED(obj) GTK_CHECK_CAST (obj, gtk_hpaned_get_type (), GtkHPaned)
-#define GTK_HPANED_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_hpaned_get_type (), GtkHPanedClass)
-#define GTK_IS_HPANED(obj) GTK_CHECK_TYPE (obj, gtk_hpaned_get_type ())
+#define GTK_TYPE_HPANED (gtk_hpaned_get_type ())
+#define GTK_HPANED(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_HPANED, GtkHPaned))
+#define GTK_HPANED_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_HPANED, GtkHPanedClass))
+#define GTK_IS_HPANED(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_HPANED))
+#define GTK_IS_HPANED_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_HPANED))
+#define GTK_HPANED_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_HPANED, GtkHPanedClass))
typedef struct _GtkHPaned GtkHPaned;
diff --git a/gtk/gtkhruler.c b/gtk/gtkhruler.c
index ab9cef0c6d..d827de748a 100644
--- a/gtk/gtkhruler.c
+++ b/gtk/gtkhruler.c
@@ -65,7 +65,7 @@ gtk_hruler_get_type (void)
(GtkClassInitFunc) NULL,
};
- hruler_type = gtk_type_unique (gtk_ruler_get_type (), &hruler_info);
+ hruler_type = gtk_type_unique (GTK_TYPE_RULER, &hruler_info);
}
return hruler_type;
@@ -100,7 +100,7 @@ gtk_hruler_init (GtkHRuler *hruler)
GtkWidget*
gtk_hruler_new (void)
{
- return GTK_WIDGET (gtk_type_new (gtk_hruler_get_type ()));
+ return GTK_WIDGET (gtk_type_new (GTK_TYPE_HRULER));
}
static gint
diff --git a/gtk/gtkhruler.h b/gtk/gtkhruler.h
index 04b2f49f84..889507c750 100644
--- a/gtk/gtkhruler.h
+++ b/gtk/gtkhruler.h
@@ -37,9 +37,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_HRULER(obj) GTK_CHECK_CAST (obj, gtk_hruler_get_type (), GtkHRuler)
-#define GTK_HRULER_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_hruler_get_type (), GtkHRulerClass)
-#define GTK_IS_HRULER(obj) GTK_CHECK_TYPE (obj, gtk_hruler_get_type ())
+#define GTK_TYPE_HRULER (gtk_hruler_get_type ())
+#define GTK_HRULER(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_HRULER, GtkHRuler))
+#define GTK_HRULER_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_HRULER, GtkHRulerClass))
+#define GTK_IS_HRULER(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_HRULER))
+#define GTK_IS_HRULER_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_HRULER))
+#define GTK_HRULER_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_HRULER, GtkHRulerClass))
typedef struct _GtkHRuler GtkHRuler;
diff --git a/gtk/gtkhscale.h b/gtk/gtkhscale.h
index 7fbeca1fbe..b253d1c73e 100644
--- a/gtk/gtkhscale.h
+++ b/gtk/gtkhscale.h
@@ -42,7 +42,7 @@ extern "C" {
#define GTK_HSCALE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_HSCALE, GtkHScaleClass))
#define GTK_IS_HSCALE(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_HSCALE))
#define GTK_IS_HSCALE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_HSCALE))
-
+#define GTK_HSCALE_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_HSCALE, GtkHScaleClass))
typedef struct _GtkHScale GtkHScale;
diff --git a/gtk/gtkhscrollbar.h b/gtk/gtkhscrollbar.h
index c06cce5b99..e1006bcada 100644
--- a/gtk/gtkhscrollbar.h
+++ b/gtk/gtkhscrollbar.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_HSCROLLBAR_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_HSCROLLBAR, GtkHScrollbarClass))
#define GTK_IS_HSCROLLBAR(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_HSCROLLBAR))
#define GTK_IS_HSCROLLBAR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_HSCROLLBAR))
+#define GTK_HSCROLLBAR_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_HSCROLLBAR, GtkHScrollbarClass))
typedef struct _GtkHScrollbar GtkHScrollbar;
diff --git a/gtk/gtkhseparator.h b/gtk/gtkhseparator.h
index e104d45b0e..faf34d9954 100644
--- a/gtk/gtkhseparator.h
+++ b/gtk/gtkhseparator.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_HSEPARATOR_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_HSEPARATOR, GtkHSeparatorClass))
#define GTK_IS_HSEPARATOR(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_HSEPARATOR))
#define GTK_IS_HSEPARATOR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_HSEPARATOR))
+#define GTK_HSEPARATOR_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_HSEPARATOR, GtkHSeparatorClass))
typedef struct _GtkHSeparator GtkHSeparator;
diff --git a/gtk/gtkimage.h b/gtk/gtkimage.h
index 945e9502cb..7bda782370 100644
--- a/gtk/gtkimage.h
+++ b/gtk/gtkimage.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_IMAGE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_IMAGE, GtkImageClass))
#define GTK_IS_IMAGE(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_IMAGE))
#define GTK_IS_IMAGE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_IMAGE))
+#define GTK_IMAGE_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_IMAGE, GtkImageClass))
typedef struct _GtkImage GtkImage;
diff --git a/gtk/gtkinputdialog.h b/gtk/gtkinputdialog.h
index 6b63c43ddd..3852491f67 100644
--- a/gtk/gtkinputdialog.h
+++ b/gtk/gtkinputdialog.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_INPUT_DIALOG_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_INPUT_DIALOG, GtkInputDialogClass))
#define GTK_IS_INPUT_DIALOG(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_INPUT_DIALOG))
#define GTK_IS_INPUT_DIALOG_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_INPUT_DIALOG))
+#define GTK_INPUT_DIALOG_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_INPUT_DIALOG, GtkInputDialogClass))
typedef struct _GtkInputDialog GtkInputDialog;
diff --git a/gtk/gtkinvisible.h b/gtk/gtkinvisible.h
index 3564fafc21..0bddc8788b 100644
--- a/gtk/gtkinvisible.h
+++ b/gtk/gtkinvisible.h
@@ -42,9 +42,10 @@ extern "C" {
#define GTK_INVISIBLE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_INVISIBLE, GtkInvisibleClass))
#define GTK_IS_INVISIBLE(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_INVISIBLE))
#define GTK_IS_INVISIBLE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_INVISIBLE))
+#define GTK_INVISIBLE_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_INVISIBLE, GtkInvisibleClass))
-typedef struct _GtkInvisible GtkInvisible;
+typedef struct _GtkInvisible GtkInvisible;
typedef struct _GtkInvisibleClass GtkInvisibleClass;
struct _GtkInvisible
diff --git a/gtk/gtkitem.h b/gtk/gtkitem.h
index 935909741a..c866a915b6 100644
--- a/gtk/gtkitem.h
+++ b/gtk/gtkitem.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_ITEM_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_ITEM, GtkItemClass))
#define GTK_IS_ITEM(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_ITEM))
#define GTK_IS_ITEM_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_ITEM))
+#define GTK_ITEM_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_ITEM, GtkItemClass))
typedef struct _GtkItem GtkItem;
diff --git a/gtk/gtkitemfactory.h b/gtk/gtkitemfactory.h
index 6b7c21e367..1b7c9ada2b 100644
--- a/gtk/gtkitemfactory.h
+++ b/gtk/gtkitemfactory.h
@@ -50,11 +50,12 @@ typedef void (*GtkItemFactoryCallback1) (gpointer callback_data,
guint callback_action,
GtkWidget *widget);
-#define GTK_TYPE_ITEM_FACTORY (gtk_item_factory_get_type ())
-#define GTK_ITEM_FACTORY(object) (GTK_CHECK_CAST (object, GTK_TYPE_ITEM_FACTORY, GtkItemFactory))
-#define GTK_ITEM_FACTORY_CLASS(klass) (GTK_CHECK_CLASS_CAST (klass, GTK_TYPE_ITEM_FACTORY, GtkItemFactoryClass))
-#define GTK_IS_ITEM_FACTORY(object) (GTK_CHECK_TYPE (object, GTK_TYPE_ITEM_FACTORY))
-#define GTK_IS_ITEM_FACTORY_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_ITEM_FACTORY))
+#define GTK_TYPE_ITEM_FACTORY (gtk_item_factory_get_type ())
+#define GTK_ITEM_FACTORY(object) (GTK_CHECK_CAST ((object), GTK_TYPE_ITEM_FACTORY, GtkItemFactory))
+#define GTK_ITEM_FACTORY_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_ITEM_FACTORY, GtkItemFactoryClass))
+#define GTK_IS_ITEM_FACTORY(object) (GTK_CHECK_TYPE ((object), GTK_TYPE_ITEM_FACTORY))
+#define GTK_IS_ITEM_FACTORY_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_ITEM_FACTORY))
+#define GTK_ITEM_FACTORY_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_ITEM_FACTORY, GtkItemFactoryClass))
typedef struct _GtkItemFactory GtkItemFactory;
diff --git a/gtk/gtklabel.h b/gtk/gtklabel.h
index e9de3df32e..74fb70e907 100644
--- a/gtk/gtklabel.h
+++ b/gtk/gtklabel.h
@@ -36,12 +36,13 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_TYPE_LABEL (gtk_label_get_type ())
-#define GTK_LABEL(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_LABEL, GtkLabel))
-#define GTK_LABEL_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_LABEL, GtkLabelClass))
-#define GTK_IS_LABEL(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_LABEL))
-#define GTK_IS_LABEL_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_LABEL))
-
+#define GTK_TYPE_LABEL (gtk_label_get_type ())
+#define GTK_LABEL(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_LABEL, GtkLabel))
+#define GTK_LABEL_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_LABEL, GtkLabelClass))
+#define GTK_IS_LABEL(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_LABEL))
+#define GTK_IS_LABEL_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_LABEL))
+#define GTK_LABEL_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_LABEL, GtkLabelClass))
+
typedef struct _GtkLabel GtkLabel;
typedef struct _GtkLabelClass GtkLabelClass;
diff --git a/gtk/gtklayout.h b/gtk/gtklayout.h
index 432c2d98e8..0cf7a12e4a 100644
--- a/gtk/gtklayout.h
+++ b/gtk/gtklayout.h
@@ -39,11 +39,14 @@
extern "C" {
#endif /* __cplusplus */
+
#define GTK_TYPE_LAYOUT (gtk_layout_get_type ())
#define GTK_LAYOUT(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_LAYOUT, GtkLayout))
#define GTK_LAYOUT_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_LAYOUT, GtkLayoutClass))
#define GTK_IS_LAYOUT(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_LAYOUT))
#define GTK_IS_LAYOUT_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_LAYOUT))
+#define GTK_LAYOUT_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_LAYOUT, GtkLayoutClass))
+
typedef struct _GtkLayout GtkLayout;
typedef struct _GtkLayoutClass GtkLayoutClass;
diff --git a/gtk/gtklist.h b/gtk/gtklist.h
index 929868735d..25beaec10a 100644
--- a/gtk/gtklist.h
+++ b/gtk/gtklist.h
@@ -43,6 +43,7 @@ extern "C" {
#define GTK_LIST_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_LIST, GtkListClass))
#define GTK_IS_LIST(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_LIST))
#define GTK_IS_LIST_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_LIST))
+#define GTK_LIST_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_LIST, GtkListClass))
typedef struct _GtkList GtkList;
diff --git a/gtk/gtklistitem.h b/gtk/gtklistitem.h
index 4d1d220824..64086b0bb3 100644
--- a/gtk/gtklistitem.h
+++ b/gtk/gtklistitem.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_LIST_ITEM_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_LIST_ITEM, GtkListItemClass))
#define GTK_IS_LIST_ITEM(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_LIST_ITEM))
#define GTK_IS_LIST_ITEM_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_LIST_ITEM))
+#define GTK_LIST_ITEM_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_LIST_ITEM, GtkListItemClass))
typedef struct _GtkListItem GtkListItem;
diff --git a/gtk/gtkmenu.h b/gtk/gtkmenu.h
index 38ddb510b8..9abfb87b52 100644
--- a/gtk/gtkmenu.h
+++ b/gtk/gtkmenu.h
@@ -43,6 +43,7 @@ extern "C" {
#define GTK_MENU_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_MENU, GtkMenuClass))
#define GTK_IS_MENU(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_MENU))
#define GTK_IS_MENU_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_MENU))
+#define GTK_MENU_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_MENU, GtkMenuClass))
typedef struct _GtkMenu GtkMenu;
diff --git a/gtk/gtkmenubar.h b/gtk/gtkmenubar.h
index b78847c618..7f0a81a7a1 100644
--- a/gtk/gtkmenubar.h
+++ b/gtk/gtkmenubar.h
@@ -36,11 +36,13 @@
extern "C" {
#endif /* __cplusplus */
-#define GTK_TYPE_MENU_BAR (gtk_menu_bar_get_type ())
-#define GTK_MENU_BAR(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_MENU_BAR, GtkMenuBar))
-#define GTK_MENU_BAR_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_MENU_BAR, GtkMenuBarClass))
-#define GTK_IS_MENU_BAR(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_MENU_BAR))
-#define GTK_IS_MENU_BAR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_MENU_BAR))
+
+#define GTK_TYPE_MENU_BAR (gtk_menu_bar_get_type ())
+#define GTK_MENU_BAR(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_MENU_BAR, GtkMenuBar))
+#define GTK_MENU_BAR_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_MENU_BAR, GtkMenuBarClass))
+#define GTK_IS_MENU_BAR(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_MENU_BAR))
+#define GTK_IS_MENU_BAR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_MENU_BAR))
+#define GTK_MENU_BAR_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_MENU_BAR, GtkMenuBarClass))
typedef struct _GtkMenuBar GtkMenuBar;
diff --git a/gtk/gtkmenuitem.h b/gtk/gtkmenuitem.h
index 81a492b4c5..310d722053 100644
--- a/gtk/gtkmenuitem.h
+++ b/gtk/gtkmenuitem.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_MENU_ITEM_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_MENU_ITEM, GtkMenuItemClass))
#define GTK_IS_MENU_ITEM(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_MENU_ITEM))
#define GTK_IS_MENU_ITEM_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_MENU_ITEM))
+#define GTK_MENU_ITEM_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_MENU_ITEM, GtkMenuItemClass))
typedef struct _GtkMenuItem GtkMenuItem;
diff --git a/gtk/gtkmenushell.h b/gtk/gtkmenushell.h
index 6230f8ad28..08d93b3ae9 100644
--- a/gtk/gtkmenushell.h
+++ b/gtk/gtkmenushell.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_MENU_SHELL_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_MENU_SHELL, GtkMenuShellClass))
#define GTK_IS_MENU_SHELL(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_MENU_SHELL))
#define GTK_IS_MENU_SHELL_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_MENU_SHELL))
+#define GTK_MENU_SHELL_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_MENU_SHELL, GtkMenuShellClass))
typedef struct _GtkMenuShell GtkMenuShell;
diff --git a/gtk/gtkmisc.h b/gtk/gtkmisc.h
index 1deb004a86..535a30ec37 100644
--- a/gtk/gtkmisc.h
+++ b/gtk/gtkmisc.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_MISC_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_MISC, GtkMiscClass))
#define GTK_IS_MISC(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_MISC))
#define GTK_IS_MISC_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_MISC))
+#define GTK_MISC_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_MISC, GtkMiscClass))
typedef struct _GtkMisc GtkMisc;
diff --git a/gtk/gtknotebook.h b/gtk/gtknotebook.h
index 553ea537e4..b407a51383 100644
--- a/gtk/gtknotebook.h
+++ b/gtk/gtknotebook.h
@@ -42,6 +42,8 @@ extern "C" {
#define GTK_NOTEBOOK_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_NOTEBOOK, GtkNotebookClass))
#define GTK_IS_NOTEBOOK(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_NOTEBOOK))
#define GTK_IS_NOTEBOOK_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_NOTEBOOK))
+#define GTK_NOTEBOOK_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_NOTEBOOK, GtkNotebookClass))
+
#define GTK_NOTEBOOK_PAGE(_glist_) ((GtkNotebookPage *)((GList *)(_glist_))->data)
diff --git a/gtk/gtkoptionmenu.h b/gtk/gtkoptionmenu.h
index bdd84bc0bc..33765f192e 100644
--- a/gtk/gtkoptionmenu.h
+++ b/gtk/gtkoptionmenu.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_OPTION_MENU_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_OPTION_MENU, GtkOptionMenuClass))
#define GTK_IS_OPTION_MENU(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_OPTION_MENU))
#define GTK_IS_OPTION_MENU_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_OPTION_MENU))
+#define GTK_OPTION_MENU_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_OPTION_MENU, GtkOptionMenuClass))
typedef struct _GtkOptionMenu GtkOptionMenu;
diff --git a/gtk/gtkpacker.h b/gtk/gtkpacker.h
index 11f53d67a4..6bae3d6c28 100644
--- a/gtk/gtkpacker.h
+++ b/gtk/gtkpacker.h
@@ -42,7 +42,7 @@ extern "C" {
#define GTK_PACKER_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_PACKER, GtkPackerClass))
#define GTK_IS_PACKER(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_PACKER))
#define GTK_IS_PACKER_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_PACKER))
-
+#define GTK_PACKER_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_PACKER, GtkPackerClass))
typedef struct _GtkPacker GtkPacker;
diff --git a/gtk/gtkpaned.h b/gtk/gtkpaned.h
index b89eb0e45e..6c7cb06785 100644
--- a/gtk/gtkpaned.h
+++ b/gtk/gtkpaned.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_PANED_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_PANED, GtkPanedClass))
#define GTK_IS_PANED(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_PANED))
#define GTK_IS_PANED_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_PANED))
+#define GTK_PANED_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_PANED, GtkPanedClass))
typedef struct _GtkPaned GtkPaned;
diff --git a/gtk/gtkpixmap.h b/gtk/gtkpixmap.h
index e00a4f6411..fd6f40bfbe 100644
--- a/gtk/gtkpixmap.h
+++ b/gtk/gtkpixmap.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_PIXMAP_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_PIXMAP, GtkPixmapClass))
#define GTK_IS_PIXMAP(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_PIXMAP))
#define GTK_IS_PIXMAP_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_PIXMAP))
+#define GTK_PIXMAP_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_PIXMAP, GtkPixmapClass))
typedef struct _GtkPixmap GtkPixmap;
diff --git a/gtk/gtkplug.c b/gtk/gtkplug.c
index 78737d2155..ea68dd97aa 100644
--- a/gtk/gtkplug.c
+++ b/gtk/gtkplug.c
@@ -73,7 +73,7 @@ gtk_plug_get_type ()
(GtkArgGetFunc) NULL
};
- plug_type = gtk_type_unique (gtk_window_get_type (), &plug_info);
+ plug_type = gtk_type_unique (GTK_TYPE_WINDOW, &plug_info);
}
return plug_type;
@@ -88,7 +88,7 @@ gtk_plug_class_init (GtkPlugClass *class)
widget_class = (GtkWidgetClass *)class;
window_class = (GtkWindowClass *)class;
- parent_class = gtk_type_class (gtk_window_get_type ());
+ parent_class = gtk_type_class (GTK_TYPE_WINDOW);
widget_class->realize = gtk_plug_realize;
widget_class->unrealize = gtk_plug_unrealize;
@@ -128,7 +128,7 @@ gtk_plug_new (guint32 socket_id)
{
GtkPlug *plug;
- plug = GTK_PLUG (gtk_type_new (gtk_plug_get_type ()));
+ plug = GTK_PLUG (gtk_type_new (GTK_TYPE_PLUG));
gtk_plug_construct (plug, socket_id);
return GTK_WIDGET (plug);
}
diff --git a/gtk/gtkplug.h b/gtk/gtkplug.h
index 6489c0f6db..8bb91ca16e 100644
--- a/gtk/gtkplug.h
+++ b/gtk/gtkplug.h
@@ -36,9 +36,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_PLUG(obj) GTK_CHECK_CAST (obj, gtk_plug_get_type (), GtkPlug)
-#define GTK_PLUG_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_plug_get_type (), GtkPlugClass)
-#define GTK_IS_PLUG(obj) GTK_CHECK_TYPE (obj, gtk_plug_get_type ())
+#define GTK_TYPE_PLUG (gtk_plug_get_type ())
+#define GTK_PLUG(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_PLUG, GtkPlug))
+#define GTK_PLUG_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_PLUG, GtkPlugClass))
+#define GTK_IS_PLUG(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_PLUG))
+#define GTK_IS_PLUG_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_PLUG))
+#define GTK_PLUG_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_PLUG, GtkPlugClass))
typedef struct _GtkPlug GtkPlug;
diff --git a/gtk/gtkpreview.h b/gtk/gtkpreview.h
index 73073abcb7..bc7c8fe26f 100644
--- a/gtk/gtkpreview.h
+++ b/gtk/gtkpreview.h
@@ -41,6 +41,7 @@ extern "C" {
#define GTK_PREVIEW_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_PREVIEW, GtkPreviewClass))
#define GTK_IS_PREVIEW(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_PREVIEW))
#define GTK_IS_PREVIEW_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_PREVIEW))
+#define GTK_PREVIEW_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_PREVIEW, GtkPreviewClass))
typedef struct _GtkPreview GtkPreview;
diff --git a/gtk/gtkprogress.h b/gtk/gtkprogress.h
index c2a8540ed1..b4bd959f6d 100644
--- a/gtk/gtkprogress.h
+++ b/gtk/gtkprogress.h
@@ -43,6 +43,7 @@ extern "C" {
#define GTK_PROGRESS_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_PROGRESS, GtkProgressClass))
#define GTK_IS_PROGRESS(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_PROGRESS))
#define GTK_IS_PROGRESS_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_PROGRESS))
+#define GTK_PROGRESS_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_PROGRESS, GtkProgressClass))
typedef struct _GtkProgress GtkProgress;
diff --git a/gtk/gtkprogressbar.h b/gtk/gtkprogressbar.h
index 5a5d9d1fc2..7db79df174 100644
--- a/gtk/gtkprogressbar.h
+++ b/gtk/gtkprogressbar.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_PROGRESS_BAR_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_PROGRESS_BAR, GtkProgressBarClass))
#define GTK_IS_PROGRESS_BAR(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_PROGRESS_BAR))
#define GTK_IS_PROGRESS_BAR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_PROGRESS_BAR))
+#define GTK_PROGRESS_BAR_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_PROGRESS_BAR, GtkProgressBarClass))
typedef struct _GtkProgressBar GtkProgressBar;
diff --git a/gtk/gtkradiobutton.h b/gtk/gtkradiobutton.h
index 0e6d599da4..465c1631d8 100644
--- a/gtk/gtkradiobutton.h
+++ b/gtk/gtkradiobutton.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_RADIO_BUTTON_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_RADIO_BUTTON, GtkRadioButtonClass))
#define GTK_IS_RADIO_BUTTON(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_RADIO_BUTTON))
#define GTK_IS_RADIO_BUTTON_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_RADIO_BUTTON))
+#define GTK_RADIO_BUTTON_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_RADIO_BUTTON, GtkRadioButtonClass))
typedef struct _GtkRadioButton GtkRadioButton;
diff --git a/gtk/gtkradiomenuitem.h b/gtk/gtkradiomenuitem.h
index aa56485b41..41f933381f 100644
--- a/gtk/gtkradiomenuitem.h
+++ b/gtk/gtkradiomenuitem.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_RADIO_MENU_ITEM_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_RADIO_MENU_ITEM, GtkRadioMenuItemClass))
#define GTK_IS_RADIO_MENU_ITEM(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_RADIO_MENU_ITEM))
#define GTK_IS_RADIO_MENU_ITEM_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_RADIO_MENU_ITEM))
+#define GTK_RADIO_MENU_ITEM_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_RADIO_MENU_ITEM, GtkRadioMenuItemClass))
typedef struct _GtkRadioMenuItem GtkRadioMenuItem;
diff --git a/gtk/gtkrange.h b/gtk/gtkrange.h
index 477d33daa9..c82c9b5d7a 100644
--- a/gtk/gtkrange.h
+++ b/gtk/gtkrange.h
@@ -43,6 +43,7 @@ extern "C" {
#define GTK_RANGE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_RANGE, GtkRangeClass))
#define GTK_IS_RANGE(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_RANGE))
#define GTK_IS_RANGE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_RANGE))
+#define GTK_RANGE_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_RANGE, GtkRangeClass))
typedef struct _GtkRange GtkRange;
diff --git a/gtk/gtkruler.h b/gtk/gtkruler.h
index 45b7013a4c..e9367bbc9f 100644
--- a/gtk/gtkruler.h
+++ b/gtk/gtkruler.h
@@ -42,6 +42,8 @@ extern "C" {
#define GTK_RULER_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_RULER, GtkRulerClass))
#define GTK_IS_RULER(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_RULER))
#define GTK_IS_RULER_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_RULER))
+#define GTK_RULER_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_RULER, GtkRulerClass))
+
typedef struct _GtkRuler GtkRuler;
typedef struct _GtkRulerClass GtkRulerClass;
diff --git a/gtk/gtkscale.h b/gtk/gtkscale.h
index 1ef44c5f24..63ab9b0c62 100644
--- a/gtk/gtkscale.h
+++ b/gtk/gtkscale.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_SCALE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_SCALE, GtkScaleClass))
#define GTK_IS_SCALE(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_SCALE))
#define GTK_IS_SCALE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_SCALE))
+#define GTK_SCALE_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_SCALE, GtkScaleClass))
typedef struct _GtkScale GtkScale;
diff --git a/gtk/gtkscrollbar.h b/gtk/gtkscrollbar.h
index aa1026d14b..400773fa03 100644
--- a/gtk/gtkscrollbar.h
+++ b/gtk/gtkscrollbar.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_SCROLLBAR_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_SCROLLBAR, GtkScrollbarClass))
#define GTK_IS_SCROLLBAR(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_SCROLLBAR))
#define GTK_IS_SCROLLBAR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_SCROLLBAR))
+#define GTK_SCROLLBAR_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_SCROLLBAR, GtkScrollbarClass))
typedef struct _GtkScrollbar GtkScrollbar;
diff --git a/gtk/gtkscrolledwindow.h b/gtk/gtkscrolledwindow.h
index 569d270472..f0d8c4fb6e 100644
--- a/gtk/gtkscrolledwindow.h
+++ b/gtk/gtkscrolledwindow.h
@@ -44,6 +44,8 @@ extern "C" {
#define GTK_SCROLLED_WINDOW_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_SCROLLED_WINDOW, GtkScrolledWindowClass))
#define GTK_IS_SCROLLED_WINDOW(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_SCROLLED_WINDOW))
#define GTK_IS_SCROLLED_WINDOW_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_SCROLLED_WINDOW))
+#define GTK_SCROLLED_WINDOW_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_SCROLLED_WINDOW, GtkScrolledWindowClass))
+
typedef struct _GtkScrolledWindow GtkScrolledWindow;
diff --git a/gtk/gtkseparator.h b/gtk/gtkseparator.h
index 03fe0fc1aa..de787308de 100644
--- a/gtk/gtkseparator.h
+++ b/gtk/gtkseparator.h
@@ -42,6 +42,8 @@ extern "C" {
#define GTK_SEPARATOR_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_SEPARATOR, GtkSeparatorClass))
#define GTK_IS_SEPARATOR(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_SEPARATOR))
#define GTK_IS_SEPARATOR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_SEPARATOR))
+#define GTK_SEPARATOR_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_SEPARATOR, GtkSeparatorClass))
+
typedef struct _GtkSeparator GtkSeparator;
diff --git a/gtk/gtksocket.c b/gtk/gtksocket.c
index e5bdeac276..6be2af88e4 100644
--- a/gtk/gtksocket.c
+++ b/gtk/gtksocket.c
@@ -71,7 +71,7 @@ static GdkFilterReturn gtk_socket_filter_func (GdkXEvent *gdk_xevent,
static GtkWidgetClass *parent_class = NULL;
GtkType
-gtk_socket_get_type ()
+gtk_socket_get_type (void)
{
static GtkType socket_type = 0;
@@ -88,7 +88,7 @@ gtk_socket_get_type ()
(GtkArgGetFunc) NULL
};
- socket_type = gtk_type_unique (gtk_container_get_type (), &socket_info);
+ socket_type = gtk_type_unique (GTK_TYPE_CONTAINER, &socket_info);
}
return socket_type;
@@ -105,7 +105,7 @@ gtk_socket_class_init (GtkSocketClass *class)
widget_class = (GtkWidgetClass*) class;
container_class = (GtkContainerClass*) class;
- parent_class = gtk_type_class (gtk_widget_get_type ());
+ parent_class = gtk_type_class (GTK_TYPE_CONTAINER);
widget_class->realize = gtk_socket_realize;
widget_class->unrealize = gtk_socket_unrealize;
@@ -133,11 +133,11 @@ gtk_socket_init (GtkSocket *socket)
}
GtkWidget*
-gtk_socket_new ()
+gtk_socket_new (void)
{
GtkSocket *socket;
- socket = gtk_type_new (gtk_socket_get_type ());
+ socket = gtk_type_new (GTK_TYPE_SOCKET);
return GTK_WIDGET (socket);
}
@@ -403,7 +403,7 @@ gtk_socket_focus_out_event (GtkWidget *widget, GdkEventFocus *event)
g_return_val_if_fail (GTK_IS_SOCKET (widget), FALSE);
socket = GTK_SOCKET (widget);
- toplevel = gtk_widget_get_ancestor (widget, gtk_window_get_type());
+ toplevel = gtk_widget_get_ancestor (widget, GTK_TYPE_WINDOW);
if (toplevel)
{
@@ -698,7 +698,7 @@ gtk_socket_filter_func (GdkXEvent *gdk_xevent, GdkEvent *event, gpointer data)
{
#if 0
GtkWidget *toplevel;
- toplevel = gtk_widget_get_ancestor (widget, gtk_window_get_type());
+ toplevel = gtk_widget_get_ancestor (widget, GTK_TYPE_WINDOW);
if (toplevel)
{
@@ -757,11 +757,11 @@ gtk_socket_filter_func (GdkXEvent *gdk_xevent, GdkEvent *event, gpointer data)
#elif defined (GDK_WINDOWING_WIN32)
-guint
-gtk_socket_get_type ()
+GtkType
+gtk_socket_get_type (void)
{
g_error ("GtkSocket not implemented");
- return 42;
+ return 0;
}
GtkWidget*
diff --git a/gtk/gtksocket.h b/gtk/gtksocket.h
index df98fdc4d9..4b91788e1b 100644
--- a/gtk/gtksocket.h
+++ b/gtk/gtksocket.h
@@ -33,9 +33,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_SOCKET(obj) GTK_CHECK_CAST (obj, gtk_socket_get_type (), GtkSocket)
-#define GTK_SOCKET_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_socket_get_type (), GtkSocketClass)
-#define GTK_IS_SOCKET(obj) GTK_CHECK_TYPE (obj, gtk_socket_get_type ())
+#define GTK_TYPE_SOCKET (gtk_socket_get_type ())
+#define GTK_SOCKET(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_SOCKET, GtkSocket))
+#define GTK_SOCKET_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_SOCKET, GtkSocketClass))
+#define GTK_IS_SOCKET(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_SOCKET))
+#define GTK_IS_SOCKET_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_SOCKET))
+#define GTK_SOCKET_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_SOCKET, GtkSocketClass))
typedef struct _GtkSocket GtkSocket;
@@ -64,7 +67,7 @@ struct _GtkSocketClass
GtkWidget* gtk_socket_new (void);
-GtkType gtk_socket_get_type (void );
+GtkType gtk_socket_get_type (void);
void gtk_socket_steal (GtkSocket *socket,
guint32 wid);
diff --git a/gtk/gtkspinbutton.h b/gtk/gtkspinbutton.h
index f07074ba44..e3a9fba8b1 100644
--- a/gtk/gtkspinbutton.h
+++ b/gtk/gtkspinbutton.h
@@ -46,6 +46,7 @@ extern "C" {
#define GTK_SPIN_BUTTON_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_SPIN_BUTTON, GtkSpinButtonClass))
#define GTK_IS_SPIN_BUTTON(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_SPIN_BUTTON))
#define GTK_IS_SPIN_BUTTON_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_SPIN_BUTTON))
+#define GTK_SPIN_BUTTON_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_SPIN_BUTTON, GtkSpinButtonClass))
#define INPUT_ERROR -1
diff --git a/gtk/gtkstatusbar.c b/gtk/gtkstatusbar.c
index f1d21fa306..34603573fb 100644
--- a/gtk/gtkstatusbar.c
+++ b/gtk/gtkstatusbar.c
@@ -68,7 +68,7 @@ gtk_statusbar_get_type (void)
(GtkClassInitFunc) NULL,
};
- statusbar_type = gtk_type_unique (gtk_hbox_get_type (), &statusbar_info);
+ statusbar_type = gtk_type_unique (GTK_TYPE_HBOX, &statusbar_info);
}
return statusbar_type;
@@ -85,7 +85,7 @@ gtk_statusbar_class_init (GtkStatusbarClass *class)
widget_class = (GtkWidgetClass *) class;
container_class = (GtkContainerClass *) class;
- parent_class = gtk_type_class (gtk_hbox_get_type ());
+ parent_class = gtk_type_class (GTK_TYPE_HBOX);
statusbar_signals[SIGNAL_TEXT_PUSHED] =
gtk_signal_new ("text_pushed",
@@ -148,7 +148,7 @@ gtk_statusbar_init (GtkStatusbar *statusbar)
GtkWidget*
gtk_statusbar_new (void)
{
- return gtk_type_new (gtk_statusbar_get_type ());
+ return gtk_type_new (GTK_TYPE_STATUSBAR);
}
static void
diff --git a/gtk/gtkstatusbar.h b/gtk/gtkstatusbar.h
index 713bc16daa..c388124f56 100644
--- a/gtk/gtkstatusbar.h
+++ b/gtk/gtkstatusbar.h
@@ -34,9 +34,14 @@
extern "C" {
#endif /* __cplusplus */
-#define GTK_STATUSBAR(obj) GTK_CHECK_CAST (obj, gtk_statusbar_get_type (), GtkStatusbar)
-#define GTK_STATUSBAR_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_statusbar_get_type (), GtkStatusbarClass)
-#define GTK_IS_STATUSBAR(obj) GTK_CHECK_TYPE (obj, gtk_statusbar_get_type ())
+
+#define GTK_TYPE_STATUSBAR (gtk_statusbar_get_type ())
+#define GTK_STATUSBAR(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_STATUSBAR, GtkStatusbar))
+#define GTK_STATUSBAR_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_STATUSBAR, GtkStatusbarClass))
+#define GTK_IS_STATUSBAR(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_STATUSBAR))
+#define GTK_IS_STATUSBAR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_STATUSBAR))
+#define GTK_STATUSBAR_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_STATUSBAR, GtkStatusbarClass))
+
typedef struct _GtkStatusbar GtkStatusbar;
typedef struct _GtkStatusbarClass GtkStatusbarClass;
diff --git a/gtk/gtktable.h b/gtk/gtktable.h
index 75f78bbec1..7fe7a782af 100644
--- a/gtk/gtktable.h
+++ b/gtk/gtktable.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_TABLE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_TABLE, GtkTableClass))
#define GTK_IS_TABLE(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_TABLE))
#define GTK_IS_TABLE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_TABLE))
+#define GTK_TABLE_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_TABLE, GtkTableClass))
typedef struct _GtkTable GtkTable;
diff --git a/gtk/gtktearoffmenuitem.h b/gtk/gtktearoffmenuitem.h
index cbdd5ee055..3ff7e1a35f 100644
--- a/gtk/gtktearoffmenuitem.h
+++ b/gtk/gtktearoffmenuitem.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_TEAROFF_MENU_ITEM_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_TEAROFF_MENU_ITEM, GtkTearoffMenuItemClass))
#define GTK_IS_TEAROFF_MENU_ITEM(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_TEAROFF_MENU_ITEM))
#define GTK_IS_TEAROFF_MENU_ITEM_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_TEAROFF_MENU_ITEM))
+#define GTK_TEAROFF_MENU_ITEM_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_TEAROFF_MENU_ITEM, GtkTearoffMenuItemClass))
typedef struct _GtkTearoffMenuItem GtkTearoffMenuItem;
diff --git a/gtk/gtktext.h b/gtk/gtktext.h
index c1194a31cd..c49bb66015 100644
--- a/gtk/gtktext.h
+++ b/gtk/gtktext.h
@@ -42,6 +42,8 @@ extern "C" {
#define GTK_TEXT_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_TEXT, GtkTextClass))
#define GTK_IS_TEXT(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_TEXT))
#define GTK_IS_TEXT_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_TEXT))
+#define GTK_TEXT_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_TEXT, GtkTextClass))
+
typedef struct _GtkTextFont GtkTextFont;
typedef struct _GtkPropertyMark GtkPropertyMark;
diff --git a/gtk/gtktipsquery.h b/gtk/gtktipsquery.h
index c6b94b94df..c3d3f8d2d7 100644
--- a/gtk/gtktipsquery.h
+++ b/gtk/gtktipsquery.h
@@ -45,6 +45,7 @@ extern "C" {
#define GTK_TIPS_QUERY_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_TIPS_QUERY, GtkTipsQueryClass))
#define GTK_IS_TIPS_QUERY(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_TIPS_QUERY))
#define GTK_IS_TIPS_QUERY_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_TIPS_QUERY))
+#define GTK_TIPS_QUERY_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_TIPS_QUERY, GtkTipsQueryClass))
/* --- typedefs --- */
diff --git a/gtk/gtktogglebutton.h b/gtk/gtktogglebutton.h
index 0b654c3fc4..2f1d6c16f1 100644
--- a/gtk/gtktogglebutton.h
+++ b/gtk/gtktogglebutton.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_TOGGLE_BUTTON_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_TOGGLE_BUTTON, GtkToggleButtonClass))
#define GTK_IS_TOGGLE_BUTTON(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_TOGGLE_BUTTON))
#define GTK_IS_TOGGLE_BUTTON_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_TOGGLE_BUTTON))
+#define GTK_TOGGLE_BUTTON_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_TOGGLE_BUTTON, GtkToggleButtonClass))
typedef struct _GtkToggleButton GtkToggleButton;
diff --git a/gtk/gtktoolbar.h b/gtk/gtktoolbar.h
index 3c82eb2bc0..0b62f73358 100644
--- a/gtk/gtktoolbar.h
+++ b/gtk/gtktoolbar.h
@@ -47,6 +47,8 @@ extern "C" {
#define GTK_TOOLBAR_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_TOOLBAR, GtkToolbarClass))
#define GTK_IS_TOOLBAR(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_TOOLBAR))
#define GTK_IS_TOOLBAR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_TOOLBAR))
+#define GTK_TOOLBAR_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_TOOLBAR, GtkToolbarClass))
+
typedef enum
{
diff --git a/gtk/gtktooltips.h b/gtk/gtktooltips.h
index 0d57cdd8da..e270650c5e 100644
--- a/gtk/gtktooltips.h
+++ b/gtk/gtktooltips.h
@@ -35,11 +35,14 @@
extern "C" {
#endif /* __cplusplus */
+
#define GTK_TYPE_TOOLTIPS (gtk_tooltips_get_type ())
#define GTK_TOOLTIPS(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_TOOLTIPS, GtkTooltips))
#define GTK_TOOLTIPS_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_TOOLTIPS, GtkTooltipsClass))
#define GTK_IS_TOOLTIPS(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_TOOLTIPS))
#define GTK_IS_TOOLTIPS_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_TOOLTIPS))
+#define GTK_TOOLTIPS_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_TOOLTIPS, GtkTooltipsClass))
+
typedef struct _GtkTooltips GtkTooltips;
typedef struct _GtkTooltipsClass GtkTooltipsClass;
diff --git a/gtk/gtktree.h b/gtk/gtktree.h
index 9ddb5e9c69..699d93a601 100644
--- a/gtk/gtktree.h
+++ b/gtk/gtktree.h
@@ -44,6 +44,8 @@ extern "C" {
#define GTK_TREE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_TREE, GtkTreeClass))
#define GTK_IS_TREE(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_TREE))
#define GTK_IS_TREE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_TREE))
+#define GTK_TREE_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_TREE, GtkTreeClass))
+
#define GTK_IS_ROOT_TREE(obj) ((GtkObject*) GTK_TREE(obj)->root_tree == (GtkObject*)obj)
#define GTK_TREE_ROOT_TREE(obj) (GTK_TREE(obj)->root_tree ? GTK_TREE(obj)->root_tree : GTK_TREE(obj))
diff --git a/gtk/gtktreeitem.h b/gtk/gtktreeitem.h
index d63658857e..3388cbbb8d 100644
--- a/gtk/gtktreeitem.h
+++ b/gtk/gtktreeitem.h
@@ -42,6 +42,8 @@ extern "C" {
#define GTK_TREE_ITEM_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_TREE_ITEM, GtkTreeItemClass))
#define GTK_IS_TREE_ITEM(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_TREE_ITEM))
#define GTK_IS_TREE_ITEM_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_TREE_ITEM))
+#define GTK_TREE_ITEM_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_TREE_ITEM, GtkTreeItemClass))
+
#define GTK_TREE_ITEM_SUBTREE(obj) (GTK_TREE_ITEM(obj)->subtree)
diff --git a/gtk/gtktypeutils.h b/gtk/gtktypeutils.h
index 190a36cbde..ee5d50b05f 100644
--- a/gtk/gtktypeutils.h
+++ b/gtk/gtktypeutils.h
@@ -103,6 +103,7 @@ typedef enum
# define GTK_CHECK_CLASS_CAST(tclass,cast_type,cast) \
((cast*) gtk_type_check_class_cast ((GtkTypeClass*) (tclass), (cast_type)))
#endif /* GTK_NO_CHECK_CASTS */
+#define GTK_CHECK_GET_CLASS(obj,type,klass) ((klass*) (((GtkTypeObject*) (obj))->klass))
/* Determines whether `type_object' and `type_class' are a type of `otype'.
*/
diff --git a/gtk/gtkvbbox.c b/gtk/gtkvbbox.c
index 686f0e16e2..63a633828b 100644
--- a/gtk/gtkvbbox.c
+++ b/gtk/gtkvbbox.c
@@ -56,7 +56,7 @@ gtk_vbutton_box_get_type (void)
(GtkClassInitFunc) NULL,
};
- vbutton_box_type = gtk_type_unique (gtk_button_box_get_type (), &vbutton_box_info);
+ vbutton_box_type = gtk_type_unique (GTK_TYPE_BUTTON_BOX, &vbutton_box_info);
}
return vbutton_box_type;
@@ -84,7 +84,7 @@ gtk_vbutton_box_new (void)
{
GtkVButtonBox *vbutton_box;
- vbutton_box = gtk_type_new (gtk_vbutton_box_get_type ());
+ vbutton_box = gtk_type_new (GTK_TYPE_VBUTTON_BOX);
return GTK_WIDGET (vbutton_box);
}
diff --git a/gtk/gtkvbbox.h b/gtk/gtkvbbox.h
index e8775c933d..65cfd4b7db 100644
--- a/gtk/gtkvbbox.h
+++ b/gtk/gtkvbbox.h
@@ -36,9 +36,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_VBUTTON_BOX(obj) GTK_CHECK_CAST (obj, gtk_vbutton_box_get_type (), GtkVButtonBox)
-#define GTK_VBUTTON_BOX_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_vbutton_box_get_type (), GtkVButtonBoxClass)
-#define GTK_IS_VBUTTON_BOX(obj) GTK_CHECK_TYPE (obj, gtk_vbutton_box_get_type ())
+#define GTK_TYPE_VBUTTON_BOX (gtk_vbutton_box_get_type ())
+#define GTK_VBUTTON_BOX(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_VBUTTON_BOX, GtkVButtonBox))
+#define GTK_VBUTTON_BOX_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_VBUTTON_BOX, GtkVButtonBoxClass))
+#define GTK_IS_VBUTTON_BOX(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_VBUTTON_BOX))
+#define GTK_IS_VBUTTON_BOX_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_VBUTTON_BOX))
+#define GTK_VBUTTON_BOX_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_VBUTTON_BOX, GtkVButtonBoxClass))
typedef struct _GtkVButtonBox GtkVButtonBox;
diff --git a/gtk/gtkvbox.h b/gtk/gtkvbox.h
index 7366c5efa9..00c887a934 100644
--- a/gtk/gtkvbox.h
+++ b/gtk/gtkvbox.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_VBOX_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_VBOX, GtkVBoxClass))
#define GTK_IS_VBOX(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_VBOX))
#define GTK_IS_VBOX_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_VBOX))
+#define GTK_VBOX_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_VBOX, GtkVBoxClass))
typedef struct _GtkVBox GtkVBox;
diff --git a/gtk/gtkviewport.h b/gtk/gtkviewport.h
index 31d279c366..40e042b2c0 100644
--- a/gtk/gtkviewport.h
+++ b/gtk/gtkviewport.h
@@ -43,6 +43,7 @@ extern "C" {
#define GTK_VIEWPORT_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_VIEWPORT, GtkViewportClass))
#define GTK_IS_VIEWPORT(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_VIEWPORT))
#define GTK_IS_VIEWPORT_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_VIEWPORT))
+#define GTK_VIEWPORT_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_VIEWPORT, GtkViewportClass))
typedef struct _GtkViewport GtkViewport;
diff --git a/gtk/gtkvpaned.c b/gtk/gtkvpaned.c
index e1ebaebc68..ece7f19486 100644
--- a/gtk/gtkvpaned.c
+++ b/gtk/gtkvpaned.c
@@ -63,7 +63,7 @@ gtk_vpaned_get_type (void)
(GtkClassInitFunc) NULL,
};
- vpaned_type = gtk_type_unique (gtk_paned_get_type (), &vpaned_info);
+ vpaned_type = gtk_type_unique (GTK_TYPE_PANED, &vpaned_info);
}
return vpaned_type;
@@ -94,7 +94,7 @@ gtk_vpaned_new (void)
{
GtkVPaned *vpaned;
- vpaned = gtk_type_new (gtk_vpaned_get_type ());
+ vpaned = gtk_type_new (GTK_TYPE_VPANED);
return GTK_WIDGET (vpaned);
}
diff --git a/gtk/gtkvpaned.h b/gtk/gtkvpaned.h
index a88002e043..08382ee9ab 100644
--- a/gtk/gtkvpaned.h
+++ b/gtk/gtkvpaned.h
@@ -37,9 +37,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_VPANED(obj) GTK_CHECK_CAST (obj, gtk_vpaned_get_type (), GtkVPaned)
-#define GTK_VPANED_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_vpaned_get_type (), GtkVPanedClass)
-#define GTK_IS_VPANED(obj) GTK_CHECK_TYPE (obj, gtk_vpaned_get_type ())
+#define GTK_TYPE_VPANED (gtk_vpaned_get_type ())
+#define GTK_VPANED(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_VPANED, GtkVPaned))
+#define GTK_VPANED_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_VPANED, GtkVPanedClass))
+#define GTK_IS_VPANED(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_VPANED))
+#define GTK_IS_VPANED_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_VPANED))
+#define GTK_VPANED_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_VPANED, GtkVPanedClass))
typedef struct _GtkVPaned GtkVPaned;
diff --git a/gtk/gtkvruler.c b/gtk/gtkvruler.c
index 8c684e8e08..dec56a3bf5 100644
--- a/gtk/gtkvruler.c
+++ b/gtk/gtkvruler.c
@@ -65,7 +65,7 @@ gtk_vruler_get_type (void)
(GtkClassInitFunc) NULL,
};
- vruler_type = gtk_type_unique (gtk_ruler_get_type (), &vruler_info);
+ vruler_type = gtk_type_unique (GTK_TYPE_RULER, &vruler_info);
}
return vruler_type;
@@ -99,7 +99,7 @@ gtk_vruler_init (GtkVRuler *vruler)
GtkWidget*
gtk_vruler_new (void)
{
- return GTK_WIDGET (gtk_type_new (gtk_vruler_get_type ()));
+ return GTK_WIDGET (gtk_type_new (GTK_TYPE_VRULER));
}
diff --git a/gtk/gtkvruler.h b/gtk/gtkvruler.h
index 9426825830..23a12e5c88 100644
--- a/gtk/gtkvruler.h
+++ b/gtk/gtkvruler.h
@@ -37,9 +37,12 @@ extern "C" {
#endif /* __cplusplus */
-#define GTK_VRULER(obj) GTK_CHECK_CAST (obj, gtk_vruler_get_type (), GtkVRuler)
-#define GTK_VRULER_CLASS(klass) GTK_CHECK_CLASS_CAST (klass, gtk_vruler_get_type (), GtkVRulerClass)
-#define GTK_IS_VRULER(obj) GTK_CHECK_TYPE (obj, gtk_vruler_get_type ())
+#define GTK_TYPE_VRULER (gtk_vruler_get_type ())
+#define GTK_VRULER(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_VRULER, GtkVRuler))
+#define GTK_VRULER_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_VRULER, GtkVRulerClass))
+#define GTK_IS_VRULER(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_VRULER))
+#define GTK_IS_VRULER_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_VRULER))
+#define GTK_VRULER_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_VRULER, GtkVRulerClass))
typedef struct _GtkVRuler GtkVRuler;
diff --git a/gtk/gtkvscale.h b/gtk/gtkvscale.h
index 86969492df..73efc798f7 100644
--- a/gtk/gtkvscale.h
+++ b/gtk/gtkvscale.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_VSCALE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_VSCALE, GtkVScaleClass))
#define GTK_IS_VSCALE(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_VSCALE))
#define GTK_IS_VSCALE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_VSCALE))
+#define GTK_VSCALE_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_VSCALE, GtkVScaleClass))
typedef struct _GtkVScale GtkVScale;
diff --git a/gtk/gtkvscrollbar.h b/gtk/gtkvscrollbar.h
index 3011112f13..29754e884c 100644
--- a/gtk/gtkvscrollbar.h
+++ b/gtk/gtkvscrollbar.h
@@ -37,6 +37,7 @@
#define GTK_VSCROLLBAR_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_VSCROLLBAR, GtkVScrollbarClass))
#define GTK_IS_VSCROLLBAR(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_VSCROLLBAR))
#define GTK_IS_VSCROLLBAR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_VSCROLLBAR))
+#define GTK_VSCROLLBAR_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_VSCROLLBAR, GtkVScrollbarClass))
typedef struct _GtkVScrollbar GtkVScrollbar;
diff --git a/gtk/gtkvseparator.h b/gtk/gtkvseparator.h
index ed08e762f8..a1ed8791c6 100644
--- a/gtk/gtkvseparator.h
+++ b/gtk/gtkvseparator.h
@@ -42,6 +42,7 @@ extern "C" {
#define GTK_VSEPARATOR_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_VSEPARATOR, GtkVSeparatorClass))
#define GTK_IS_VSEPARATOR(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_VSEPARATOR))
#define GTK_IS_VSEPARATOR_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_VSEPARATOR))
+#define GTK_VSEPARATOR_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_VSEPARATOR, GtkVSeparatorClass))
typedef struct _GtkVSeparator GtkVSeparator;
diff --git a/gtk/gtkwidget.h b/gtk/gtkwidget.h
index 51ac815d7a..ff6523d31c 100644
--- a/gtk/gtkwidget.h
+++ b/gtk/gtkwidget.h
@@ -71,6 +71,7 @@ typedef enum
#define GTK_WIDGET_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_WIDGET, GtkWidgetClass))
#define GTK_IS_WIDGET(widget) (GTK_CHECK_TYPE ((widget), GTK_TYPE_WIDGET))
#define GTK_IS_WIDGET_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_WIDGET))
+#define GTK_WIDGET_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_WIDGET, GtkWidgetClass))
/* Macros for extracting various fields from GtkWidget and GtkWidgetClass.
*/
diff --git a/gtk/gtkwindow.h b/gtk/gtkwindow.h
index 53d22948ab..1bf69438f6 100644
--- a/gtk/gtkwindow.h
+++ b/gtk/gtkwindow.h
@@ -40,10 +40,11 @@ extern "C" {
#define GTK_TYPE_WINDOW (gtk_window_get_type ())
-#define GTK_WINDOW(obj) (GTK_CHECK_CAST (obj, GTK_TYPE_WINDOW, GtkWindow))
-#define GTK_WINDOW_CLASS(klass) (GTK_CHECK_CLASS_CAST (klass, GTK_TYPE_WINDOW, GtkWindowClass))
-#define GTK_IS_WINDOW(obj) (GTK_CHECK_TYPE (obj, GTK_TYPE_WINDOW))
-#define GTK_IS_WINDOW_CLASS(klass) (GTK_CHECK_CLASS_TYPE (klass, GTK_TYPE_WINDOW))
+#define GTK_WINDOW(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_WINDOW, GtkWindow))
+#define GTK_WINDOW_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_WINDOW, GtkWindowClass))
+#define GTK_IS_WINDOW(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_WINDOW))
+#define GTK_IS_WINDOW_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_WINDOW))
+#define GTK_WINDOW_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GTK_TYPE_WINDOW, GtkWindowClass))
typedef struct _GtkWindow GtkWindow;