[pygtk] DrawingArea and mouse events

Donn donn.ingle at gmail.com
Fri Nov 9 17:51:58 WST 2007


> What you're looking for is, for some reason or another, known as a
> "canvas".  
Okay. It seems I am writing my own canvas then. I am stuck on GTL+2.8 for a 
bunch of reasons so I have not been able to run any of the popular canvas 
apps.

> People on the list might have suggestions for sorting through these.
Right, more questions to a general audience then:-

I hope someone can point me in the direction of how to calculate when an x,y 
is within the area of an object - based on it's closed-path shape not a 
general bounding area. That's something I am all at sea about.

For the "bubbling" of events through my objects, I think I have an angle on it 
and can start hacking.

One other thing puzzles me; how to know when a given object is occluded by 
others on the canvas? Is it worth trying to find those situations or just 
handle the, say, mouse-over event even if that object is covered by five 
others? 

\d


More information about the pygtk mailing list