kansasjayhawk
Programmer
I am building a simple GUI with Tcl/Tk, part of which is recording data to a file. As the file grows, I want to display its size, refreshed maybe every second or two. If I write a very simple loop that does this, all other pointer events on the GUI don't respond. If I update idle tasks at the end of this loop, they at least respond every time that line is reached. I think I need a timer to insert
every two seconds into the list of events being processed. Or somehow concurrently respond to events on the GUI and refresh this file size. I've considered creating another interpreter, but it would still need to access the original GUI, and I'm back to the same problem of updating it. This seems fundamental, but I can't seem to solve it.
Code:
.fileSizelbl configure -text [file size data.dat]