[Rd] win variable in tcltk

Gabor Grothendieck ggrothendieck at myway.com
Tue Dec 28 17:52:37 CET 2004



The following gives an error message:

library(tcltk)

win <- list(env="A") 

tt <- tktoplevel()
but <- tkbutton(tt, text="X", command=expression(tkdestroy(tt)))
tkgrid(but)

however, if one comments out the win line (and removes the
win variable) then it works.  It seems that tcltk is making
use of a variable called win with a component name of env
and I just happened to have a list in my workspace called win
in which one of the components was called env.  I suggest that
this either be changed or documented.  I spent quite a large
amount of time until I realized what was going on.



More information about the R-devel mailing list