May 2018
Beginner to intermediate
452 pages
11h 26m
English
As a major component of the GUI, our menu is clearly a view, and should be implemented in the views.py file. However, it's also going to need to set options that affect other views (such as the form options we're implementing now) and run functions that affect the application (like quitting). We need to implement it in such a way that we keep controller functions in the Application class but still keep the UI code in views.py. Let's take a look at the following steps:
class MainMenu(tk.Menu): """The Application's main menu"""
Our overridden __init__() method will take two dictionaries, a settings dictionary and ...