]> granicus.if.org Git - python/commit
Several optimizations:
authorBarry Warsaw <barry@python.org>
Wed, 18 Feb 1998 00:05:59 +0000 (00:05 +0000)
committerBarry Warsaw <barry@python.org>
Wed, 18 Feb 1998 00:05:59 +0000 (00:05 +0000)
commitf67a50c2e1b1afffd2ce49d4e53356e95a0efea0
treefebb955456515b16bf7c885027d11ec2393d5d72
parent8d3e5ee552b70512b13a910da594b5c32f3e9c26
Several optimizations:

    self.__chips now contains the list of rgbtuple values for the
    chips named i - 1 (Tkinter counts from 1, we count from zero).
    The chip number was just the index + 1.  This means color lookup
    need not do an itemcget(), it can just index into __chips.

    instead of calling __canvas.itemconfigure(), we glom up a huge Tcl
    script and call tk.eval() directly.  Actually we do many appends
    to a Python list, then string.join() them together into one huge
    string.  This reduces the overhead of Tkinter but making one fast
    call to Tcl.
Tools/pynche/StripViewer.py