Re: [gtk-list] Re: Callback Argument Marshalling



Kenneth Albanowski <kjahds@kjahds.com> writes:

> On Thu, 6 Aug 1998 beach@ataman.com wrote:
> 
> > How does it work with the low-level (GdkEvent) signals? 
> 
> That's the rub: all passed structure pointers (like GdkEvent) will be
> passed as a raw pointer, with type "pointer".  Currently disambiguating
> such types requires manual assistance, in some form or another. 

The Gtk type system is able to differentiate between random pointers
(GTK_TYPE_POINTER) and pointers to specific structures (say GdkEvent,
GTK_TYPE_GDK_EVENT).

Uses of GTK_TYPE_POINTER naturally pose problems for programs that
want to dynamically query the types of pointers, like interpreter
bindings.  So using GTK_TYPE_POINTER should be avoided whenever
possible.  I think most of Gtk+ is free of GTK_TYPE_POINTER.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]