TkPane is a Python package designed to simplify the construction of a Tkinter user interface by encapsulating one or more widgets into ‘pane’ objects that have no direct dependence on any other UI elements. Panes interact with other application elements only through a standardized interface of methods and callback functions. The tkpane package allows custom panes to be created that can be easily re-used in multiple applications. When multiple panes are assembled for use in a single UI, and some panes require data from other panes, each such dependency can be established with a simple method call. Panes that manage data (e.g., user entries) can automatically pass that data to other panes. Other application code can also easily obtain a pane’s data in the form of a Python dictionary.
The tkpane package provides the TkPane class, which should be subclassed to create pane objects that contain whatever combination of Tkinter widgets and behavior is desired. Several general-purpose custom panes are provided in the tkpane.lib package. These pane classes can be used as-is, or used as templates for the construction of other custom pane classes.