The Checkbutton widget

import tkinter as tk
from tkinter import ttk

parent = tk.Tk()
my_boolean_var = tk.BooleanVar()

my_checkbutton = ttk.Checkbutton(
    text="Check to make this option True",
    variable=my_boolean_var
)
my_checkbutton.pack()
parent.mainloop()

Discover more from Tips and Hints for Aerospace Engineers

Subscribe now to keep reading and get access to the full archive.

Continue reading