easymodel.cascade
¶
This module provides classes for viewing a multi-level hierarchy. Imagine you have a treemodel and a combobox for each level which only shows the part of the hierarchy beneath the selected parent index in the higher-level combobox. So each time the user selects an entry in the combobox, all levels beneath automatically get updated and change their root to the selected index.
The main base class is AbstractCascadeView
which handles the
logic for automatically updating the lower levels.
Each level of the hierarchy is displayed by a AbstractLevel
.
A level could be a single combobox, a listview or any other widget that you
want to use.
There are also some simple, useful implementations:
Classes¶
AbstractCascadeView (depth[, parent, flags]) |
A abstract class for a cascade view |
AbstractLevel (*args, **kwargs) |
Mixin for QtGui.QWidget for a level of a cascade view. |
CBLevel ([parent]) |
A level that consists of a simple combobox to be used in a CascadeView |
ComboBoxCascadeView (depth[, parent, flags, ...]) |
A cascade view that has a combo box for every level and a label for every header. |
ListCascadeView (depth[, parent, flags, headers]) |
A cascade view that has a list view for every level and a label for every header. |
ListLevel ([parent]) |
A level that consists of a listview to be used in a CascadeView |