example - pp \gui\tools\threadtools-test-classes py tests thread callback queuebut uses class bound methods for action and callbacks import time from threadtools import threadcheckerstartthread from tkinter scrolledtext import scrolledtext class myguidef __init__(selfreps= )self reps reps uses default tk root self text scrolledtext(save widget as state self text pack(threadchecker(self textstart thread check loop self text bind('' need list for maprange ok lambda eventlist(map(self oneventrange( ))def onevent(selfi)myname 'thread-%si startthreadaction self threadactionargs ( )context (myname,)onexit self threadexitonfail self threadfailonprogress self threadprogressthread' main action def threadaction(selfidprogress)code that spawns thread what the thread does guisthreadsand queues