Threads and tkinter

All Tcl commands need to originate from the same thread. Due to tkinter‘s dependence on Tcl, it’s generally necessary to make all tkinter gui statements originate from the same thread. The problem occurs because mainWindow is instantiated in the tkinterGui thread, but — because mainWindow is an attribute of tkinterGui — is not destroyed until … Read more

List of All Tkinter Events

A general list for Bindings and Events can be found on effbot.org or in the docs provided by New Mexico Tech whereas the name of several keys are listed here in addition to the original documentation. Here’s a summary of the most common events with some keypress names explained: Event Description <Button-1> Button 1 is … Read more

how to get the time after two minutes [closed]

To get the date-string in bash: echo “Current: ” $(date +”%Y”-“%m”-“%d”T”%H”-“%M”-“%S”) echo “+2 min : ” $(date –date=”@$(($(date +%s)+120))” +”%Y”-“%m”-“%d”T”%H”-“%M”-“%S”) prints Current: 2014-09-10T15-58-15 +2 min : 2014-09-10T16-00-15 Read the time from string and print +2min string str=”2014-09-10T15-58-15″ new=$(date –date=”@$(($( IFS=”-T” read y m d H M S <<< “$str”;date –date=”$y-$m-${d}T$H:$M:$S” +%s )+120))” +”%Y”-“%m”-“%d”T”%H”-“%M”-“%S”) echo “From … Read more

TCL can’t find mistake [closed]

There are several problems with your script. The first of which is on the first line: set QA1 array() This doesn’t do what you think it does. What it does is create a scalar variable (not an array) that contains the seven character string “array()”. Later you try to access it as an array: set … Read more