Tiny eg
#!/bin/env wish9
ttk::menubutton .moreButton -text More -underline 0
menu .moreButton.menu
.moreButton.menu add command -label Test -underline 0 \
-command {puts "Test"}
.moreButton configure -menu .moreButton.menu
pack .moreButton
bind . <Escape> {exit}
bind . <Alt-m> {.moreButton invoke} ;# WRONG!
If I click the More button the menu pops up and works correctly.
But I cannot see how to do a binding that will make the menu
pop up when I press <Alt-m>. How can I do this?
Sysop: | DaiTengu |
---|---|
Location: | Appleton, WI |
Users: | 1,071 |
Nodes: | 10 (0 / 10) |
Uptime: | 41:07:13 |
Calls: | 13,753 |
Calls today: | 1 |
Files: | 186,983 |
D/L today: |
8,502 files (2,589M bytes) |
Messages: | 2,424,798 |