19. Themed Widgets

Themed widgets take a different approach from the classic Tk widget set. They separate, to the extent possible, the code implementing a widget’s behavior from the code implementing its appearance. While classic widgets are configured through the option database or by directly modifying options on each widget, the size, shape, color, fonts, and so on of themed widgets are controlled by their style. Themed widgets allow an application’s look and feel to be controlled by its environment (e.g., Windows user preferences) or by centralized application-defined styles. The resulting appearance is more consistent throughout the application, as well as with the native look and feel of the user’s windowing system.

19.1 Comparing Classic ...

Get Tcl and the Tk Toolkit, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.