-
-
Notifications
You must be signed in to change notification settings - Fork 32.6k
Closed
Labels
Description
The docstring: """Return the resource value for a KEY given as string."""
claims it returns as a string however it returns a _tkinter.Tcl_Obj
which seems to lack __eq__
/the ability to compare it to a string so something like this:
is_normal = radio_button.cget("state") == tk.NORMAL
Will always return false no matter what unless its wrapped in a str()
I propose either clarifying the docstr or returning as a str() wrapped obj but i presume that's a breaking change
Linked PRs
- gh-126008: Fix the type of return value for
ttk.Widget.cget
#126102 - gh-126008: Improve docstrings for Tkinter cget and configure methods #133303
- [3.14] gh-126008: Improve docstrings for Tkinter cget and configure methods (GH-133303) #137660
- [3.13] gh-126008: Improve docstrings for Tkinter cget and configure methods (GH-133303) #137661
Metadata
Metadata
Assignees
Labels
Projects
Status
Todo