Skip to content

Commit 277e653

Browse files
committed
https://github.com/python/cpython/pull/7287#discussion_r192546254
1 parent 61c23d2 commit 277e653

File tree

1 file changed

+13
-10
lines changed

1 file changed

+13
-10
lines changed

Doc/library/tkinter.rst

Lines changed: 13 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -48,16 +48,21 @@ Tk
4848
Tk is a module that can be loaded into a Tcl interpreter instance. It adds
4949
Tcl commands (implemented in C) to create and manipulate GUI widgets. Each
5050
:class:`Tk` object embeds its own Tcl interpreter instance with Tk loaded into
51-
it. Tk's widgets are very customizable, though at the cost of a dated appearance.
51+
it.
5252
Tk uses Tcl's event queue to generate and process GUI events. Note
5353
that unlike some GUI libraries, each interpreter uses only a single thread,
5454
which has implications for :mod:`tkinter` users (see `Threading model`_).
5555

56-
Ttk
57-
Themed Tk (Ttk) is a newer family of Tk widgets that provide a much better
58-
appearance on different platforms than many of the classic Tk widgets.
59-
Ttk is distributed as part of Tk, starting with Tk version 8.5. Python
60-
bindings are provided in a separate module, :mod:`tkinter.ttk`.
56+
Since version 8.5, Tk also implements the
57+
`Themed Tk (Ttk) <https://www.tcl.tk/man/tcl8.6/TkCmd/ttk_intro.htm>`_
58+
family of widgets.
59+
They are intended to be the new standard and are recommended
60+
for use in new code. The key improvement is they separate
61+
appearance and behavior logic and consolidate the former into a "theme".
62+
This greately simplifies widget interface and configuration and gives
63+
a consistent and more modern and native look across different OSes.
64+
Python bindings for Ttk are provided in a separate module,
65+
:mod:`tkinter.ttk`.
6166

6267
Tix
6368
`Tix`<https://core.tcl.tk/jenglish/gutter/packages/tix.html>_ is an older
@@ -68,10 +73,8 @@ Tix
6873
Tkinter Modules
6974
^^^^^^^^^^^^^^^
7075

71-
Most applications will directly use the features provided by :mod:`tkinter`.
72-
Unless compatibility with very old versions of Tcl/Tk is required, Ttk widgets
73-
found in :mod:`tkinter.ttk` should also be favoured over their classic Tk
74-
counterparts.
76+
:mod:`tkinter` has the core functionality and the bindings for regular Tk
77+
widgets.
7578

7679
The :mod:`_tkinter` module provides low-level access to Tcl interpreters in Python,
7780
using the C interface to the Tcl library. It should rarely be used directly by

0 commit comments

Comments
 (0)