converted to Tk application