Oh well, thanks for the answer.<div><br></div><div>Is there much data on how much of a delay is needed, and does it vary much from computer to computer? I'm trying to produce a smooth animation with the more complicated code, so adding a big delay isn't acceptable.</div>
<div>-Leon<br><br><div class="gmail_quote">On Sat, Jan 12, 2013 at 9:58 AM, Kevin Walzer <span dir="ltr"><<a href="mailto:kw@codebykevin.com" target="_blank">kw@codebykevin.com</a>></span> wrote:<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

You're running into a well-known and essentially unsolvable bug with Tk on OS X, essentially integration between the event loop of Tk and Cocoa's event loop. This is not a Tkinter issue, it's a Tk issue, and it's essentially impossible to fix: the event loops of Tk and Cocoa are very different and their integration is a fragile, leading at times to the kinds of screen freeze/lockups you see. Increasing the delay between events a bit, as you've done, is a recommended best practice, as it gives the event loop time to spin and process the event queue; so you've essentially already found the best solution for your problem.<br>

<br>
I'm speaking here at the maintainer of Tk on the Mac; we've discussed these issues on the Tcl-Mac mailing list, the MacPython list, and here, and a lot of talented developers besides myself have looked at it. No one has been able to solve the issue, it's simply an inherent artifact that can only be worked around.<br>

<br>
Thanks,<br>
Kevin<br></blockquote></div></div>