Re: Where'd my gtk+-1.2 mouse events go ?
- From: Noah Levitt <nlevitt columbia edu>
- To: Nix <nix go-nix ca>
- Cc: gtk-app-devel-list gnome org
- Subject: Re: Where'd my gtk+-1.2 mouse events go ?
- Date: Thu, 14 Aug 2003 09:25:13 -0400
Call gdk_window_get_pointer () in your motion notify
handler. Read about this in the scribble part of the
(Why on earth are you developing for gtk+ 1.2?!)
On Thu, Aug 14, 2003 at 1:36:43 -0600, Nix wrote:
Hi ! I have a drawing area inside a viewport inside a scrollwindow. I
have set the followings on the drawing area:
gtk_widget_set_events (GTK_WIDGET (drawing_area), GDK_EXPOSURE_MASK
This should give me unfettered access to all mouse and mouse motion
events. That is, if I were to add a printf to the motion_notify
handler, when I move the mouse, it should dowse the terminal in printf
messages, right ? Well, not in my case, for some reason.
I have printfs for button_press_event, motion_notify_event, and
button_release_event. When the mouse enters the drawing area, it
generates exactly 1 (!) motion event. If I depress the mouse button, it
generates 1 button_press_event (unsurprisingly). If I then drag the
mouse, it once again generates exactly 1 motion event. Why only 1 ?
This seems to work well enough on other windows.
Does the scrollwindow, or the viewport my drawing area is embedded in
absorb the motion and mouse button events ?
] [Thread Prev