From the course: Python GUI Development with Tkinter
Unlock the full course today
Join today to access over 24,800 courses taught by industry experts.
Configuring widget styles
From the course: Python GUI Development with Tkinter
Configuring widget styles
- [Narrator] In this course we've learned how to create and configure a wide variety of tk widgets and up to this point we've only configured the appearance of one widget at a time by modifying it's properties. For one or two widgets, that's fine, but as our user interfaces continue to grow in scale it can become cumbersome to individually configure the look of every widget. Fortunately the themed tk module has a mechanism to help us with what is called styles. A style describes how a widget will appear depending on it's state. Tk widgets can be one or more of the ten possible states at any given time depending on how the widget has been configured and how the user is currently interacting with it. For detailed definition of what each of these states represents refer to the tk documentation on widgets. With the tk style you can describe how a widget might glow when the user hovers their mouse over it, or how to make it look subdued and grayed out if it's been disabled. Since every…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
-
-
(Locked)
Entering and displaying multiple lines with the Text widget11m 31s
-
(Locked)
Adding tags, marks, images, and widgets to the Text widget9m 57s
-
(Locked)
Building a hierarchical treeview7m 19s
-
(Locked)
Adding columns and selecting items in the Treeview7m 12s
-
(Locked)
Building cascading menus11m 5s
-
(Locked)
Drawing a basic line on the Canvas5m 21s
-
(Locked)
Drawing complex shapes on the Canvas9m 58s
-
(Locked)
Attaching a scroll bar to widgets6m 21s
-
(Locked)
Configuring widget styles9m 49s
-
(Locked)
Prompting users with the Messagebox and dialogs6m 11s
-
(Locked)
-
-
-
-