When I have code like this, I would like to be able to
store the index number of particular options for later use.
menu .mbar
. config -menu .mbar
.mbar add cascade -label "File" -underline 0 \
-menu [menu .mbar.file -tearoff 0]
.mbar add cascade -label "Help" -underline 0 \
-menu [menu .mbar.help -tearoff 0]
set m .mbar.file
$m add command -label "Open Test Suite" -underline 0 \
-command gui::opentestsuite
This simple patch does what I need. There is probably
extra work/thinking to do to make sure that everything
is consistent...
Logged In: YES
user_id=79902
Seems like a good idea to me (the index won't necessarily be
valid if you change the -tearoff option or insert new
entries, but that's easily resolvable using careful
documentation)
Needs microTIP.