3 #define GtkObject_val(obj) ((GtkObject*)Field(obj,1))
4 value Val_GtkObject (GtkObject *w);
5 value Val_GtkObject_sink (GtkObject *w);
6 #define GtkAccelGroup_val(val) ((GtkAccelGroup*)Pointer_val(val))
7 value Val_GtkAccelGroup (GtkAccelGroup *);
8 #define GtkStyle_val(val) ((GtkStyle*)Pointer_val(val))
9 value Val_GtkStyle (GtkStyle *);
11 #define Val_GtkAny(w) Val_GtkObject((GtkObject*)w)
12 #define Val_GtkAny_sink(w) Val_GtkObject_sink((GtkObject*)w)
13 #define Val_GtkWidget Val_GtkAny
14 #define Val_GtkWidget_sink Val_GtkAny_sink
16 #ifdef GTK_NO_CHECK_CASTS
17 #define check_cast(f,v) f(Pointer_val(v))
19 #define check_cast(f,v) (Pointer_val(v) == NULL ? NULL : f(Pointer_val(v)))
22 #define GtkWidget_val(val) check_cast(GTK_WIDGET,val)
23 #define GtkAdjustment_val(val) check_cast(GTK_ADJUSTMENT,val)
24 #define GtkItem_val(val) check_cast(GTK_ITEM,val)