tkinter-checkbox

self.chkProgMode = tk.IntVar()
tk.Checkbutton(topFrame2, text="设计模式", variable=self.chkProgMode, command=self.on_chk_ProgMode).pack(side=tk.LEFT, padx=4)

# 默认选择
self.chkProgMode.set(True)