The control system (guictrl.ctrl) is the central orchestration layer for all GUI controls.
guictrl.ctrl manages:
- Control tree — Hierarchical parent-child relationships
- Command routing — Dispatch actions from controls to application handlers
- Inter-control communication — Controls signaling each other
- Namespace extension — Dynamic namespace modification by plugins
Tag Definition → Tag Parser → Factory Creation → Parent Attachment → Layout → Event Wiring → Display
Controls interact through:
- Command routing — action="save_record" routes to the application's save handler
- Event propagation — Changes bubble up through the control tree
- Signal system — Pub/sub between unrelated controls
- Data binding — Controls bound to model fields auto-update
The control namespace is dynamically extended at runtime by plugins:
# In guictrl.ctrl:
SchBaseCtrl = ... # Exported for plugin use
HTML2 = None # Set by webview plugins (cef, wxwebview) at runtime
This allows plugins to replace or extend core control functionality without modifying framework code.
Pytigon provides a comprehensive set of standard controls:
- Input controls — Text, choice, combo, numeric, date/time pickers (guictrl.input)
- Button controls — Standard buttons, toolbar-integrated buttons (guictrl.button)
- Grid container — wxGrid-compatible layout with cell editors (guictrl.grids)
- Panel container — Scrolling, docking panels (guictrl.panels)
- Popups — Modal dialogs, HTML popups, select2-style selectors (guictrl.popup)
See individual control documentation for detailed usage of each control type.