TkXext

TkXext is an extension to Tcl/Tk that provides the abilities to embed foreign applications (based on their title), record events to a script, and playback that script, and various other useful things related to these features.