Re: mouse events

>hi!  How do I capture mouse events?  The particular
>event I'm interested in is mouse move/click/drag.  For
>mouse move, I've tried signal_drag_motion() and
>signal_motion_notify_event().  More specifically, I
>have a DrawingArea class and I have overridden the two
>functions I mentioned.  Moving the mose over the
>DrawingArea does nothing.  It should print out
>something with cout.

DrawingAreas do not receive mouse events by default. You see to call
add_events() or set_events(). 

>One more question, how do I capture resize events
>within the DrawingArea?

you probably want to connect to signal_configure_event.

>I've googled for this but it seems that gtkmm has very
>few resources available.  Or am I just not looking in
>the right places?

you are not looking in the right places. 

>I'm new to gtkmm and would really appreciate if you
>gave me sample code.  Thanks!

get the source distribution and look in the examples directory, or
find it online.


>Yahoo! Messenger 
>Show us what our next emoticon should look like. Join the fun. 
>gtkmm-list mailing list
>gtkmm-list gnome org

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