menu entries and scheme variables
Tk allows menu entries to be tied to variables--so you can do
{.mymenu add checkbutton :label on :variable mymenuIsOn}
and then setting the variable `mymenuIsOn' changes the checkbutton's state,
and clicking on the checkbutton sets the variable.
We can do this in STk(los), but as far as I can tell,
* the variable has to have a global name, so you can pass it in
by name.
* the variable will be set to "0" or "1", not #f or #t.
I assume this is just part of the whole problem of passing non-strings to Tk,
and I don't mean to complain. I just wanted to check with the list: Am I
missing a way to pass in non-global variables? (I tried using address-of in
various ways, and they didn't seem to work.) Alternatively, has anybody
written code to make this interface cleaner?
Received on Mon Jul 24 1995 - 22:28:07 CEST
This archive was generated by hypermail 2.3.0
: Mon Jul 21 2014 - 19:38:59 CEST