Home

ttk

ttk, short for themed Tk, is a collection of widgets for the Tk GUI toolkit that provides a modern, platform-native appearance. It originated with Tk 8.5 as an upgrade to the classic Tk widget set and is designed to produce consistent visuals across Windows, macOS, and Unix-like systems. In Python, ttk is accessed via the tkinter.ttk module, but the widgets are part of the underlying Tcl/Tk runtime.

Themed widgets differ in appearance from their classic Tk counterparts and are controlled through a styling

Widgets provided by ttk cover common interface elements and containers, including buttons, labels, entries, checkbuttons, radiobuttons,

ttk remains widely used in GUI applications built with Tcl/Tk or Tkinter, offering a more modern look-and-feel

system.
Widgets
in
ttk
are
typically
prefixed
with
a
T
to
distinguish
them
from
the
standard
Tk
widgets
(for
example,
TButton,
TLabel,
TEntry).
The
look
and
behavior
can
be
adjusted
with
a
Style
object,
and
the
overall
look
is
selected
by
applying
a
theme.
Themes
can
be
switched
at
runtime,
enabling
different
aesthetics
without
changing
widget
code.
The
set
of
built-in
themes
includes
several
options
such
as
clam,
alt,
default,
and
classic,
and
platform-specific
themes
may
be
provided
where
available
(for
example,
xpnative
on
Windows
or
aqua
on
macOS).
comboboxes,
notebook
(tabbed
panels),
treeview
(hierarchical
displays),
paned
windows,
progress
bars,
scales,
separators,
and
labelframes.
The
widgets
aim
to
be
more
visually
consistent
and
easier
to
theme
than
their
classic
Tk
counterparts,
while
remaining
compatible
with
existing
Tk
layouts
and
event
handling.
without
sacrificing
portability.