I'm creating a program which displays spreadsheet-like data using hundreds of labels. At first this works fine, however after a few redisplays it starts slowing down dramatically.
A small test program, without the distractions of the real program is: from Tkinter import * def Go(): LabelList = [] for J in range(30): print J for L in LabelList: L.grid_forget() LabelList = [] for Row in range(20): for Col in range(20): L = Label(r,text='%s'%J) L.grid(row=Row,column=Col) LabelList.append(L) r.update_idletasks() r = Tk() r.after(1000,Go) r.geometry('800x600') r.mainloop() This runs quickly at first but gradually slows down to a crawl during the latter iterations. Anyone have any idea what is causing this to go slow or how I could speed it up? I'm running Python 2.4.3 on an Ubuntu 6.06 system. Thanks Cam Farnell _______________________________________________ Tkinter-discuss mailing list Tkinter-discuss@python.org http://mail.python.org/mailman/listinfo/tkinter-discuss