TkFrame#
TkFrame is tkinter’s classic tk.Frame container, themed by ttkbootstrap
and re-exported as ttk.TkFrame. It is a plain rectangular surface used to
group and lay out other widgets. Prefer the ttk Frame
for themed layout; reach for TkFrame only when you need a classic-tk option
the ttk frame doesn’t expose (background, highlightthickness,
per-widget relief/borderwidth, an off-screen container).
Options#
Option |
Type |
Description |
|---|---|---|
|
|
Constructor only. |
|
|
The fill color of the frame. |
|
|
The 3-D border width in pixels. |
|
|
The border style: |
|
|
The width of the focus highlight drawn around the widget when it (or a child) has keyboard focus. |
|
|
The focus-highlight color when the widget has focus. |
|
|
The focus-highlight color when the widget does not have focus. |
|
|
The requested width in pixels. Ignored unless geometry propagation is
turned off ( |
|
|
The requested height in pixels. Ignored unless geometry propagation is turned off. |
|
|
Internal horizontal padding between the border and the content, in pixels. |
|
|
Internal vertical padding between the border and the content, in pixels. |
|
|
The mouse cursor over the frame (see Cursors). |
|
|
Whether the frame accepts keyboard focus during traversal. |
|
|
Constructor only. The widget class used for option-database lookups and bindtags. |
|
|
Constructor only. |
|
|
Constructor only. The X visual. Rarely needed. |
|
|
Constructor only. The X colormap. Rarely needed. |
See also#
Frame — the themed ttk container (preferred).
Tk frame manual page — the canonical upstream reference (Tcl 8.6).