def vp_start_gui(): '''Starting point when module is the main routine.''' global val, w, root root = tk.Tk() top = Toplevel1 (root) index_support.init(root, top) root.mainloop()
def create_Toplevel1(root, *args, **kwargs): '''Starting point when module is imported by another program.''' global w, w_win, rt rt = root w = tk.Toplevel (root) top = Toplevel1 (w) index_support.init(w, top, *args, **kwargs) return (w, top)
def create_Toplevel1(rt, *args, **kwargs): '''Starting point when module is imported by another module. Correct form of call: 'create_Toplevel1(root, *args, **kwargs)' .''' global w, w_win, root #rt = root root = rt w = tk.Toplevel(root) top = Toplevel1(w) index_support.init(w, top, *args, **kwargs) return (w, top)