【发布时间】:2017-03-03 17:09:07
【问题描述】:
有什么方法可以让我在 tkinter 中设置一个检查按钮,如果选中,它还会检查所有其他检查按钮吗?
例子:
Checkbutton(root, text="A").grid(row=0, column=0, sticky=W)
Checkbutton(root, text="B").grid(row=1, column=0, sticky=W)
Checkbutton(root, text="C").grid(row=2, column=0, sticky=W)
Checkbutton(root, text="ABC").grid(row=3, column=0, sticky=W)
因此,如果您要检查 ABC 按钮,则所有其他按钮也会被检查。有什么方法可以实现我想要的吗?
Python:3.4
操作系统:Windows
【问题讨论】:
标签: python python-3.x tkinter widget python-3.4