C++ wrapper - Gtk--



Looking to die with tortured screams of agony from devilish code?

Check this out if you're a C++ fan:
ftp://ftp.redhat.com/sopwith/gtk---0.1.tar.gz

If you aren't a C++ fan, then alt.masochism might be a better place,
perhaps.

Usage:
	Basically I just translated the Gtk API straight into C++ - Gtk
	is already OO so not much change except in syntax. For any Gtk
	widget 'GtkAwidget', I just changed the prefacing Gtk to Gtk_
	There's a testme.cc program that may give you a few clues if
	you're stuck (or just e-mail me).

TODO:
	- Use gtk's reference counting in constructors and destructors.
	  Otherwise we may destroy a widget that is still in use,
	  just because we created a wrapper for temporary use (when the
	  C++ objects get destroyed, their destructors also destroy
	  the encapsulated widget).
	- Quite a few of the Gtk data structures for various widgets
	  have data members that should be publicly accessable.
	  I made methods to do this in the Gtk_Dialog class just so
	  I could get a decent testme ;-) but this needs to be done
	  for everything else...
	- Anywhere where a GList or GSList is passed in or returned,
	  that is a list of GtkObjects, not Gtk_Objects. Need to do
	  translation.
	- C++ encapsulation of Gdk & Glib might be useful.

If someone else beside me could get to these todo's, it would be
appreciated (especially the last two, which are bigger tasks), since I
don't plan on spending gads of time on it.

Hope this helps, and enjoy!
-- Elliot					http://www.redhat.com/
What's nice about GUI is that you see what you manipulate.
What's bad about GUI is that you can only manipulate what you see.




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