def start_gui():
    global w, root
    root = Tk()
    root.iconbitmap('index.ico')
    top = main_level(root)
    init(root, top)
    root.mainloop()
    w = None
def start_gui():
    global w, root
    root = Tk()
    root.iconbitmap('index.ico')
    top = main_level(root)
    init(root, top)
    root.mainloop()
    w = None