Let's see how to perform the recipe:
- We will start with a Python GUI that has two tabs and then we will add more widgets to it.
- Create a new module: GUI_Complexity_start.py.
- Add the following code:
#======================# imports#======================import tkinter as tkfrom tkinter import ttkfrom tkinter import scrolledtextfrom tkinter import Menufrom tkinter import Spinboxfrom Ch11_Code.ToolTip import ToolTip
- Create a global variable and a class:
GLOBAL_CONST = 42#=================================================================== class OOP(): def __init__(self): # Create instance self.win = tk.Tk() # Add a title self.win.title("Python GUI") self.createWidgets() # Button callback def clickMe(self): self.action.configure(text='Hello ...