Hi,
I'm messing around with goocanvas, and have struggled with the animate()
method. The enums it accepts are the ones listed in the C source; they appear
to have missed the port to a C++ style.
I combined a couple of the examples, and changed the button_press method in the
demo to this:
bool Objects::_on_button_press(const Glib::RefPtr<Goocanvas::Item>& item,
GdkEventButton* ev)
{
if(ev->button == 1)
{
_dragging = item ;
_drag_x = (int) ev->x ;
_drag_y = (int) ev->y ;
std::cerr << "Clicked 1!" << std::endl ;
return true;
}
if(ev->button == 2)
{
_dragging = item ;
_drag_x = (int) ev->x ;
_drag_y = (int) ev->y ;
item->animate(100, 100, 1.0, 135, 1000, 10, Goocanvas::ANIMATE_RESET );
}
The last line refuses to compile. The enums it will accept are the C type-
this compiles and runs as hoped:
item->animate(100, 100, 1.0, 135, true, 1000, 10,
GOO_CANVAS_ANIMATE_FREEZE );
Doxygen seems to suggest the C
At this stage I think I know how to fix the library, but I'm getting very good
at breaking things and should probably leave it to someone who knows what
they're doing...
Lastly, is it worth documenting my experience as a chapter for the gtkmm manual?
__________________________________________________________________________________
Find local businesses and services in your area with Yahoo!7 Local.
Get started: http://local.yahoo.com.au_______________________________________________
gtkmm-list mailing list
[email protected]
http://mail.gnome.org/mailman/listinfo/gtkmm-list