Yaptığım Chekbuttonu ‘Sil’ adlı butona basınca ‘✓’ durumundan normal ‘boş’ duruma getirmesini istiyorum bunu nasıl yapcam.
Checkbutton’un deselect metodunu kullan.
from tkinter import *
class Sample(Tk):
def __init__(self):
super().__init__()
self.c = Checkbutton(self, text = 'Checkbutton')
self.c.pack()
b = Button(self, text = 'Deselect')
b.config(command = self._deselect)
b.pack()
def _deselect(self):
self.c.deselect()
root = Sample()
root.mainloop()