Goocanvas issues



Hey,

I'm running into a some new issues with these wrappings. The biggest
roadblock right now is the wrapping of GooCanvasTable.  Its got a list
of child properties and I'm not sure on the best way to wrap them. I
looked at Gtk::Table and its implementation. It uses a
Table_Helpers::Child class that contains the child-properties and
allows for STL-Container like access to the children. This Child uses
a GtkTableChild object thing that I don't think exists for the
GooCanvasTable equivalent.

Any help or ideas on how to wrap that object would be most welcome.

I've found a bit of a bug when using
Goocanvas::Canvas::get_root_item().  The Glib::RefPtr< Goocanvas::Item
object thats returned contains an GooCanvasItem thats only ref'ed
once. So when the RefPtr goes out of scope, the root item dies, which
causes a segfault internally in GooCanvas.

I think  I've verified this, becuase if I store the root item's RefPtr
as a class member ( so it doesn't get destroyed till the end of the
program ) the segfault disappears and when the program exits, there's
an error about g_object_unref fails the G_IS_OBJECT( object ) test (
Which I'm assuming means it got destroyed by one or the other and the
second destruction is failing.

So basically, I need to add a ref operation somewhere, but I'm
uncertain as to where this should happen.

In other news, quite a bit of the GooCanvas API has been wrapped. I'm
starting to work on getting the examples up and going.

Thanks,
Paul Davis



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