Oct-25-2019, 04:02 AM
the interactive prompt is great for running snippets of code, figuring out problems. With
tkinter it's only good for the basic app a box. All menus need to coded nothing preset, I don't have a mac but I guess it's a default by the operating system. Put your code in a file and run it. Check out elfbot tk menu it's assumes you know how import and you'll need to change the print command it's set up for python 2.7 - I modified the first example
you can find it here
best of luck
tkinter it's only good for the basic app a box. All menus need to coded nothing preset, I don't have a mac but I guess it's a default by the operating system. Put your code in a file and run it. Check out elfbot tk menu it's assumes you know how import and you'll need to change the print command it's set up for python 2.7 - I modified the first example
from tkinter import Tk, Menu root = Tk() def hello(): print( "hello!") # create a toplevel menu menubar = Menu(root) menubar.add_command(label="Hello!", command=hello) menubar.add_command(label="Quit!", command= root.destroy) # display the menu root.config(menu=menubar) root.mainloop()the link you gave is another problem they created a filedialog in the init and froze the gui. I would recommend guizero to start, it's a tkinter wrapper that is easy to create apps, then tkinter, pyqt5, wx or any other.
you can find it here
best of luck