Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: Raise canvas item to top

by Phinix (Acolyte)
on Nov 17, 2012 at 19:07 UTC ( #1004340=note: print w/ replies, xml ) Need Help??


in reply to Raise canvas item to top

I am creating right and left mouse click bindings to the node items on the main canvas. I need them to be images that blend into the main canvas background. I tried just creating each image on the main canvas, setting it to a localized variable in the process, then binding to that variable, however bind complains saying it needs an instance of a package or some such to set up bindings.

There may be another way to set up bindings on a canvas item using it's internal stack ID that I am not aware of, this is just the only way I know to make it work. Bind never complained about being set to createWindow objects on a canvas, while others do. Again, they are all items created on the same main canvas, so it theoretically shouldn't matter what they are, they should all be bind-able and follow the stacking rules.

Perhaps it works that way in newer versions of Perl/Tk. I am currently using 5.12.

For right now I am just putting the main info window for all the nodes in one fixed location (a corner) that doesn't overlap anything, so that is working for now. It would be nice however to be able to place the popup info windows adjacent to the actual item without it being covered.

Thanks for the feedback. Especially Mr. Zentara. You contribute so much around here, I just thought you deserved a special thanks!


Comment on Re: Raise canvas item to top

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (6)
As of 2014-09-02 02:47 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite cookbook is:










    Results (18 votes), past polls