A ListView Component for PyGTK
Description
This is a class that inherits from a TreeView and provides an easier API than the standard TreeView. I initially developed it for Decibel Audio Player.
This class also comes with interesting features that are not part of the standard TreeView component:
- Internal reordering with multiple selection
- Automatic and efficient sorting of columns based on multiple criteria
- The user can show/hide columns by right-clicking on columns headers
- Prevents moving a row into another row
- No need to create a ListStore, it is managed internally by the ListView
- It's possible to mark a row and to let the mark move with the row (when reordering, sorting...)
Download
Version 1.7
History
v1.7 (30/05/2010)
- The 'extlistview-modified' signal was not generated when calling clear() and replaceContent()
- Added selectRows(), removeRow(), and removeRows() method
- Really fixed the intermittent improper columns resizing
- Added the 'extlistview-selection-changed' signal
v1.6 (25/10/2008)
- Added a context menu to column headers allowing users to show/hide columns
- Improved sorting a bit
v1.5 (19/08/2008)
- Fixed intermittent improper columns resizing
v1.4 (01/01/2008)
- Replaced TYPE_INT by TYPE_PYOBJECT as the fifth parameter type of extListview-dnd (see here)
- Prevent sorting rows when the list is empty
v1.3 (22/09/2007)
- Greatly improved speed when sorting a lot of rows
- Added support for gtk.CellRendererToggle
- Improved replaceContent() method
- Added a call to set_cursor() when removing selected row(s)
- Added getFirstSelectedRow(), appendRows(), addColumnAttribute(), unselectAll() and selectAll() methods
- Set expand to False when calling pack_start()
v1.2 (02/09/2007)
- Fixed D'n'D reordering bugs
- Improved code for testing the state of the keys for mouse clicks
- Added quite a few new methods (replaceContent, hasMarkAbove, hasMarkUnder, __len__, iterSelectedRows, iterAllRows)
v1.1 (28/08/2007)
- Added a call to set_cursor() when unselecting all rows upon clicking on the empty area
- Sort indicators are now displayed whenever needed
v1.0 (23/08/2007)