Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Goo Canvas clicking pass through transparency

by renegadex (Beadle)
on Jul 25, 2008 at 01:49 UTC ( #700013=perlquestion: print w/ replies, xml ) Need Help??
renegadex has asked for the wisdom of the Perl Monks concerning the following question:

in gnome2 canvas if you have a picture with transparent areas, you can click right thru and select items that are behind the transparent area. how do i achieve this in goo canvas? in gnome2 i just simply remove the event signals and i can click items behind the transparent areas...

Comment on Goo Canvas clicking pass through transparency
Re: Goo Canvas clicking pass through transparency
by Anonymous Monk on Jul 25, 2008 at 04:41 UTC
    catch the event signal and pass to the item underneath the transparent area
Re: Goo Canvas clicking pass through transparency
by zentara (Archbishop) on Jul 25, 2008 at 14:03 UTC
    Hey, if you figure it out, post an example please. :-) From my testing, rects and ellipses with transparent centers will let the signal pass thru, but a transparent section of an image shows the image as the current item. If you look at the Goo demo, and move the toroid.png ( with a transparent center) over another item, then try to drag the item in the visible hole, the toroid moves. In the Gnome2::Canvas, the item in the hole will be detected and moved. Maybe the beta state of Goo still has this as a limitation? Maybe you could work around it by adjoining separate images, so they have a whole in them.... kind of clunky. :-)

    I'm not really a human, but I play one on earth Remember How Lucky You Are
      i got an idea.. how about putting a layer with transparent fill above the image and the transparent image? the layer at the bottom has no signal handler, instead the the layer with transparent fill recieved the signal and when moved, it moves and let the image at the bottom be dragged along with it. its like sandwiching the "transparent image w/ hole" between the "image" and the "transparent filled rectangle" !! maybe i try to make an example later. :D

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://700013]
Approved by planetscape
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (3)
As of 2014-07-31 02:23 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (244 votes), past polls