Isis 3 Programmer Reference
|
#include <ImageTreeWidget.h>
Classes | |
class | ImagePosition |
Public Types | |
enum | TreeItemContainerType { ImageGroupType = 1 , ImageListNameType } |
Signals | |
void | queueSelectionChanged () |
void | queueReadDisplayProperties () |
Public Member Functions | |
ImageTreeWidget (Directory *directory=0, QWidget *parent=0) | |
ImageTreeWidget constructor. | |
QList< QAction * > | actions () |
QTreeWidgetItem * | addGroup (QString imageListName, QString groupName="", int index=-1) |
QTreeWidgetItem * | createGroup (QTreeWidgetItem *imageListItem, QString groupName="", int index=-1) |
QTreeWidgetItem * | createImageListNameItem (QString name) |
void | refit () |
void | disableSort () |
void | enqueueReadDisplayProperties (ImageTreeWidgetItem *) |
QList< QAction * > | getViewActions () |
bool | groupInList (QList< QTreeWidgetItem * >) |
void | updateViewActs () |
ImageTreeWidgetItem * | prepCube (ImageList *imageList, Image *image) |
ImageList | imagesInView () |
Protected Member Functions | |
void | dropEvent (QDropEvent *event) |
void | mousePressEvent (QMouseEvent *event) |
This is why we needed to subclass the QTreeWidget class. | |
void | contextMenuEvent (QContextMenuEvent *event) |
Private Slots | |
QTreeWidgetItem * | addGroup () |
void | deleteSelectedGroups () |
void | imageDeleted (QObject *image) |
void | onItemChanged (QTreeWidgetItem *, int) |
void | onSelectionChanged () |
void | onQueuedReadDisplayProperties () |
void | onQueuedSelectionChanged () |
void | propertiesChanged (DisplayProperties *) |
void | renameSelectedGroup () |
void | requestCloseSelected () |
void | toggleColumnVisible () |
void | updateDragAndDropability () |
void | setDefaultFileListCols () |
Private Member Functions | |
bool | mosaicItemInList (QList< QTreeWidgetItem * >) |
ImageList | selectedDisplays () |
QTreeWidgetItem * | imageListTreeItem (QString imageListName) |
This will get the image list tree item for the given image list (by name). | |
ImageTreeWidgetItem * | treeItem (DisplayProperties *) |
ImageTreeWidgetItem * | treeItem (Image *) |
Private Attributes | |
Directory * | m_directory |
QList< QAction * > | m_viewActs |
QPointer< QAction > | m_setFileListColsAct |
QMap< DisplayProperties *, ImageTreeWidgetItem * > | m_displayPropsToTreeItemLookup |
bool | m_queuedSelectionChanged |
QList< ImageTreeWidgetItem * > | m_queuedReadDisplayPropertiesItems |
2012-09-12 Steven Lambright - createGroup() will no longer fail if a NULL image list item is provided, it will instead create the group at the root level.
2012-09-17 Steven Lambright - Optimized for 50,000+ images. Added m_displayPropsToTreeItemLookup (changed n/2 operation to log(n)). Added queued selection changed (changed some n^2 operations to n).
2013-03-19 Steven Lambright - Added setDefaultFileListCols() and set column defaults in constructor.
2013-06-27 Tracie Sucharski - Fixed bug which resulted in a seg fault when attempting to add a group to the file list. This was introduced in the changes for "a.out". Fixes #1693.
2013-07-02 Tracie Sucharski - Restored old qmos functionality for inserting new groups and fixed bug dragging and dropping groups. Fixes #1697.
Selection changes are very slow (time complexity in our code is delta-selected, but there is a very high constant that scales to the tree size - maybe an N complexity? making a total time complexity of [delta selected]*[items in view] – as bad as N^2). https://bugreports.qt-project.org/browse/QTBUG-26143. If we want this tree to no longer be a performance problem, we're going to have to rewrite it completely.
Definition at line 42 of file ImageTreeWidget.h.
enum Isis::ImageTreeWidget::TreeItemContainerType |
Definition at line 47 of file ImageTreeWidget.h.
ImageTreeWidget constructor.
ImageTreeWidget is derived from QTreeWidget
parent |
Definition at line 32 of file ImageTreeWidget.cpp.
References Isis::toBool().
|
virtual |
Definition at line 105 of file ImageTreeWidget.cpp.
Definition at line 113 of file ImageTreeWidget.cpp.
|
privateslot |
Definition at line 700 of file ImageTreeWidget.cpp.
References addGroup(), and Isis::toInt().
Referenced by addGroup().
QTreeWidgetItem * Isis::ImageTreeWidget::addGroup | ( | QString | imageListName, |
QString | groupName = "", | ||
int | index = -1 ) |
Definition at line 129 of file ImageTreeWidget.cpp.
|
protected |
Definition at line 615 of file ImageTreeWidget.cpp.
QTreeWidgetItem * Isis::ImageTreeWidget::createGroup | ( | QTreeWidgetItem * | imageListItem, |
QString | groupName = "", | ||
int | index = -1 ) |
Definition at line 141 of file ImageTreeWidget.cpp.
QTreeWidgetItem * Isis::ImageTreeWidget::createImageListNameItem | ( | QString | name | ) |
Definition at line 173 of file ImageTreeWidget.cpp.
|
privateslot |
Definition at line 729 of file ImageTreeWidget.cpp.
void Isis::ImageTreeWidget::disableSort | ( | ) |
Definition at line 209 of file ImageTreeWidget.cpp.
|
protected |
Definition at line 422 of file ImageTreeWidget.cpp.
void Isis::ImageTreeWidget::enqueueReadDisplayProperties | ( | ImageTreeWidgetItem * | item | ) |
Definition at line 214 of file ImageTreeWidget.cpp.
Definition at line 223 of file ImageTreeWidget.cpp.
bool Isis::ImageTreeWidget::groupInList | ( | QList< QTreeWidgetItem * > | items | ) |
Definition at line 870 of file ImageTreeWidget.cpp.
|
privateslot |
Definition at line 742 of file ImageTreeWidget.cpp.
|
private |
This will get the image list tree item for the given image list (by name).
This requires unique names for the image lists. If the image list name is an empty string, this will return the invisible root item (qmos). If the image list name isn't blank, but there is no such image list item in the tree, then this will create one, add it, and return it.
imageListName | The name of the image list to get the tree item for |
Definition at line 927 of file ImageTreeWidget.cpp.
ImageList Isis::ImageTreeWidget::imagesInView | ( | ) |
Definition at line 321 of file ImageTreeWidget.cpp.
|
private |
Definition at line 884 of file ImageTreeWidget.cpp.
|
protected |
This is why we needed to subclass the QTreeWidget class.
We needed our own dropEvent for the dragging and dropping of the tree widget items.
This is re-implemented to make right clicks on white space also unselect the current selection.
Definition at line 597 of file ImageTreeWidget.cpp.
|
privateslot |
Definition at line 755 of file ImageTreeWidget.cpp.
|
privateslot |
Definition at line 770 of file ImageTreeWidget.cpp.
|
privateslot |
Definition at line 790 of file ImageTreeWidget.cpp.
|
privateslot |
Definition at line 762 of file ImageTreeWidget.cpp.
ImageTreeWidgetItem * Isis::ImageTreeWidget::prepCube | ( | ImageList * | imageList, |
Image * | image ) |
Definition at line 300 of file ImageTreeWidget.cpp.
|
privateslot |
Definition at line 812 of file ImageTreeWidget.cpp.
void Isis::ImageTreeWidget::refit | ( | ) |
Definition at line 183 of file ImageTreeWidget.cpp.
|
privateslot |
Definition at line 817 of file ImageTreeWidget.cpp.
|
privateslot |
Definition at line 826 of file ImageTreeWidget.cpp.
|
private |
Definition at line 897 of file ImageTreeWidget.cpp.
|
privateslot |
Definition at line 276 of file ImageTreeWidget.cpp.
|
privateslot |
Definition at line 845 of file ImageTreeWidget.cpp.
|
private |
Definition at line 958 of file ImageTreeWidget.cpp.
|
private |
Definition at line 963 of file ImageTreeWidget.cpp.
|
privateslot |
Definition at line 856 of file ImageTreeWidget.cpp.
void Isis::ImageTreeWidget::updateViewActs | ( | ) |
Definition at line 247 of file ImageTreeWidget.cpp.
|
private |
Definition at line 141 of file ImageTreeWidget.h.
|
private |
Definition at line 144 of file ImageTreeWidget.h.
|
private |
Definition at line 147 of file ImageTreeWidget.h.
|
private |
Definition at line 145 of file ImageTreeWidget.h.
|
private |
Definition at line 143 of file ImageTreeWidget.h.
Definition at line 142 of file ImageTreeWidget.h.