[Tkinter-discuss] Adding/removing widgets from a running application?

Martin Franklin mfranklin1 at gatwick.westerngeco.slb.com
Wed Feb 27 10:28:04 CET 2008


Jim Kleckner wrote:
> Martin Franklin wrote:
>> Jim Kleckner wrote:
>>> Jim Kleckner wrote:
>>> [snip]
>>> Ok, I hacked together a grid-based demo.
>>> Care to comment on this code?
>> well, it works ;) I guess the real question is, does it do what you
>> wanted in your original post ?
> 
> I think so.  ;)  I'm not sure if I should destroy the widgets or not.
> Clearly, the grid keeps on getting more and more rows even as you
> delete (forget) some of them.  I'm not sure just what issues might
> happen when approaching it this way.
> 
> _____


I remember, before I found Tktable & its like, I attempted to create a
'spreadsheet' widget out of lots and lot (and lots) of Entry widgets
it quickly grew into a monster memory hog!

You would have to test, but I'd assume destroying the widgets will free
any memory they are using so you should not run into to many problems

Cheers,
Martin.


-- 
signature file not found, must be something I ate


More information about the Tkinter-discuss mailing list