Speeding up Simple Canvas Loop

Randall Hopper aa8vb at vislab.epa.gov
Fri May 7 13:24:22 EDT 1999


    create_line = canvas.create_line
    for line in lines:
      create_line( line, width=0 )

Can canvas items for Tkinter canvases be created by a C extension (these
vertices are actually coming from C code)?

The performance of this GUI app is acceptable except for the above loop,
and it alone can literally take minutes (400-30k iterations).

Thanks,

Randall




More information about the Python-list mailing list