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

Method _setup

tools/python-3.11.9-amd64/Lib/tkinter/__init__.py:3075–3086  ·  view source on GitHub ↗
(self, master, cnf)

Source from the content-addressed store, hash-verified

3073 Widget.__init__(self, master, 'checkbutton', cnf, kw)
3074
3075 def _setup(self, master, cnf):
3076 # Because Checkbutton defaults to a variable with the same name as
3077 # the widget, Checkbutton default names must be globally unique,
3078 # not just unique within the parent widget.
3079 if not cnf.get('name'):
3080 global _checkbutton_count
3081 name = self.__class__.__name__.lower()
3082 _checkbutton_count += 1
3083 # To avoid collisions with ttk.Checkbutton, use the different
3084 # name template.
3085 cnf['name'] = f'!{name}-{_checkbutton_count}'
3086 super()._setup(master, cnf)
3087
3088 def deselect(self):
3089 """Put the button in off-state."""

Callers

nothing calls this directly

Calls 3

getMethod · 0.45
lowerMethod · 0.45
_setupMethod · 0.45

Tested by

no test coverage detected