MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / Checkbutton

Class Checkbutton

tools/python-3.11.9-amd64/Lib/tkinter/ttk.py:590–616  ·  view source on GitHub ↗

Ttk Checkbutton widget which is either in on- or off-state.

Source from the content-addressed store, hash-verified

588
589
590class Checkbutton(Widget):
591 """Ttk Checkbutton widget which is either in on- or off-state."""
592
593 def __init__(self, master=None, **kw):
594 """Construct a Ttk Checkbutton widget with the parent master.
595
596 STANDARD OPTIONS
597
598 class, compound, cursor, image, state, style, takefocus,
599 text, textvariable, underline, width
600
601 WIDGET-SPECIFIC OPTIONS
602
603 command, offvalue, onvalue, variable
604 """
605 Widget.__init__(self, master, "ttk::checkbutton", kw)
606
607
608 def invoke(self):
609 """Toggles between the selected and deselected states and
610 invokes the associated command. If the widget is currently
611 selected, sets the option variable to the offvalue option
612 and deselects the widget; otherwise, sets the option variable
613 to the option onvalue.
614
615 Returns the result of the associated command."""
616 return self.tk.call(self._w, "invoke")
617
618
619class Entry(Widget, tkinter.Entry):

Callers 10

create_page_fontMethod · 0.90
create_page_windowsMethod · 0.90
create_page_shedMethod · 0.90
create_widgetsMethod · 0.90
create_other_buttonsMethod · 0.90
create_option_buttonsMethod · 0.90
create_extraMethod · 0.90
make_guiMethod · 0.50
addoptionsMethod · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected