title: Python/Tkinter: Destroying a window with a large canvas causes the program to stop responding
body: <p>I am maintaining a graphical parsing application written in Python with Tkinter. It optionally displays its results in a scrollable spreadsheet, which I create using a Canvas widget. However, it seems to have some scalability issues. When the main canvas is too big, trying to destroy the window in which the results are displayed causes the program to stop responding and need to be killed. When less data is being displayed, I can destroy it normally. Is this a known issue with Tkinter/large Canvi? Can I do anything to prevent these freezes?</p>
  
  <pre><code>#Function being called to destroy window
  def justexit():
      savepopup.destroy() #Destroy the popup asking to save (that called this function)
      deleteall() #Destroy canvi and their contents
      popup.destroy() #Destroy the window containing all the canvi
  
  def deleteall():
      for i, itemset in enumerate(items): #Items stores lists containing every item added to the canvi
          for item in itemset:
              canvi[i].delete(item)
          canvi[i].destroy()
  </code></pre>
  
  <p>And my estimation was a bit off. There are indeed up to tens of thousands of items in play, but I wouldn't expect the slowdown to be this glaring.</p>