I started building a python tkinter gui, the problem is, after adding many features to the gui, the loading started looking really ugly. When starting the m
The short answer is yes. You can set the window to appear as though you can't see it. Perform any code that takes time, and then display the window.
Here's how:
class MyTkRoot(tk.Tk):
def __init__(self):
tk.Tk.__init__(self)
self.attributes('-alpha', 0.0) # make window transparent
# build gui...
self.after(0, self.attributes, "-alpha", 1.0) # back to normal
root = MyTkRoot()
root.mainloop()
Here's a reference to the code with the example of a Toplevel. It will also work with the root however.