Skip to content

Commit

Permalink
Other attempt.
Browse files Browse the repository at this point in the history
  • Loading branch information
serhiy-storchaka committed May 16, 2024
1 parent a65789b commit 77e2758
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions Misc/NEWS.d/3.13.0b1.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1346,14 +1346,13 @@ urllib.
.. nonce: du4UKW
.. section: Library
Add support for passing arguments to callbacks registered in the :mod:`tkinter`
module as various Python objects (``int``, ``float``, ``bytes``, ``tuple``),
corresponding to the original Tcl value, not just ``str``, and enable this by default.
To restore the previous behavior set :mod:`!tkinter` module global
:data:`~tkinter.wantobject` to ``1`` before creating the
:class:`~tkinter.Tk` object or call the :meth:`~tkinter.Tk.wantobject`
method of the :class:`!Tk` object with argument ``1``. Calling it with
argument ``2`` restores the current default behavior.
Setting the :mod:`!tkinter` module global :data:`~tkinter.wantobject` to ``2``
before creating the :class:`~tkinter.Tk` object or call the
:meth:`~tkinter.Tk.wantobject` method of the :class:`!Tk` object with argument
``2`` makes now arguments to callbacks registered in the :mod:`tkinter` module
to be passed as various Python objects (``int``, ``float``, ``bytes``, ``tuple``),
depending on their internal represenation in Tcl, instead of always ``str``.
:data:`!tkinter.wantobject` is now set to ``2`` by default.

..
Expand Down

0 comments on commit 77e2758

Please sign in to comment.