Programmatically posting tkinter menus

D

Dan Greenblatt

I know this can be done for context menus with the 'post' command....

What I'm trying to do, though, is programmatically post non-contextual
menus (i.e. menus that exist on a horizontal menu bar at the top of my
application window) in the correct place.

So if I have five different menus (i guess these are menubuttons?)
placed horizontally on my menu bar, and the third one is 'Actions',
what is the best way to determine the x and y coordinates of these
menu items, so that i can supply these coordinates to the post command
and make the Actions menu pop up in the same place as if the user
selected the 'Actions' menubutton from the menu bar???

I'm sure there's some Tkinter trickery involved, I just don't know how
to get location information for these individual menubuttons as
opposed to the containing menu as a whole.

Thanks in advance,
Dan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,764
Messages
2,569,564
Members
45,041
Latest member
RomeoFarnh

Latest Threads

Top