Isis Developer Reference
|
This widget encompasses the entire mosaic scene. More...
#include <MosaicSceneWidget.h>
Public Slots | |
void | addImages (ImageList) |
void | removeImages (ImageList) |
void | refit () |
This method refits t:he items in the graphics view. | |
void | setCubesSelectable (bool) |
void | setProjection (Projection *) |
This method takes ownership of proj. | |
void | setOutlineRect (QRectF) |
Signals | |
void | mouseEnter () |
void | mouseMove (QPointF) |
void | mouseLeave () |
void | mouseDoubleClick (QPointF) |
void | mouseButtonPress (QPointF, Qt::MouseButton s) |
void | mouseButtonRelease (QPointF, Qt::MouseButton s) |
void | mouseWheel (QPointF, int delta) |
void | projectionChanged (Projection *) |
void | rubberBandComplete (QRectF r, Qt::MouseButton s) |
void | visibleRectChanged (QRectF) |
void | cubesChanged () |
void | queueSelectionChanged () |
void | modifyControlPoint (ControlPoint *controlPoint) |
void | deleteControlPoint (ControlPoint *controlPoint) |
void | createControlPoint (double latitude, double longitude) |
void | controlPointSelected (ControlPoint *) |
void | cnetModified () |
void | controlPointChanged (QString pointId) |
void | controlPointDeleted () |
void | mosCubeClosed (Image *) |
Public Member Functions | |
MosaicSceneWidget (QStatusBar *status, bool showTools, bool internalizeToolBarsAndProgress, Directory *directory, QWidget *parent=0) | |
Create a scene widget. | |
virtual | ~MosaicSceneWidget () |
MosaicGraphicsView * | getView () const |
QGraphicsScene * | getScene () const |
Projection * | getProjection () const |
QList< MosaicSceneItem * > | allMosaicSceneItems () |
void | addTo (QMenu *menu) |
void | addTo (ToolPad *toolPad) |
void | addToPermanent (QToolBar *toolBar) |
void | addTo (QToolBar *toolBar) |
bool | contextMenuEvent (QGraphicsSceneContextMenuEvent *event) |
This is called by MosaicGraphicsScene::contextMenuEvent. | |
MosaicSceneItem * | cubeToMosaic (Image *) |
bool | cubesSelectable () const |
void | enableRubberBand (bool) |
bool | blockSelectionChange (bool) |
bool | userHasTools () const |
QProgressBar * | getProgress () |
PvlObject | toPvl () const |
void | fromPvl (const PvlObject &) |
Call this method after loading any cubes when loading a project. | |
void | load (XmlStackedHandlerReader *xmlReader) |
void | save (QXmlStreamWriter &stream, Project *project, FileName newProjectRoot) const |
QRectF | cubesBoundingRect () const |
QStringList | cubeFileNames () |
Directory * | directory () const |
ImageList | images () |
ImageList | selectedImages () |
Returns a list of all the cubes selected in the scene. | |
QList< QAction * > | getExportActions () |
QList< QAction * > | getViewActions () |
QList< QAction * > | supportedActions (ImageList *) |
Get a list of actions this scene can perform given "images". | |
double | moveDownOne (MosaicSceneItem *) |
double | moveDownOne (Image *) |
QList< double > | moveDownOne (ImageList *) |
double | moveToBottom (MosaicSceneItem *) |
This doesn't compress the Z values - the original Z values of this scene item is guaranteed to be empty after this operation. | |
double | moveToBottom (Image *) |
This doesn't compress the Z values - the original Z value of this image is guaranteed to be empty after this operation. | |
QList< double > | moveToBottom (ImageList *) |
This doesn't compress the Z values - the original Z values of these images are guaranteed to be empty after this operation. | |
double | moveUpOne (MosaicSceneItem *) |
double | moveUpOne (Image *) |
QList< double > | moveUpOne (ImageList *) |
double | moveToTop (MosaicSceneItem *) |
This doesn't compress the Z values - the original Z values of this scene item is guaranteed to be empty after this operation. | |
double | moveToTop (Image *) |
This doesn't compress the Z values - the original Z value of this image is guaranteed to be empty after this operation. | |
QList< double > | moveToTop (ImageList *) |
This doesn't compress the Z values - the original Z values of these images are guaranteed to be empty after this operation. | |
double | moveZ (MosaicSceneItem *sceneItem, double newZ, bool newZValueMightExist=true) |
This method moves the given scene item to the given Z value. | |
double | moveZ (Image *image, double newZ, bool newZValueMightExist=true) |
template<typename DataType > | |
QList< QAction * > | supportedActions (DataType) |
Return an empty list of actions for unknown data types. | |
bool | isControlNetToolActive () |
Static Public Member Functions | |
static QWidget * | getControlNetHelp (QWidget *cnetToolContainer=NULL) |
static QWidget * | getGridHelp (QWidget *gridToolContainer=NULL) |
static QWidget * | getLongHelp (QWidget *mosaicSceneContainer=NULL) |
static QWidget * | getMapHelp (QWidget *mapContainer=NULL) |
static QWidget * | getPreviewHelp (QWidget *worldViewContainer=NULL) |
Protected Member Functions | |
virtual bool | eventFilter (QObject *obj, QEvent *ev) |
This widget encompasses the entire mosaic scene.
This widget is a self-contained 2D footprint view using Qt's graphics scene/view framework.
Isis::MosaicSceneWidget::MosaicSceneWidget | ( | QStatusBar * | status, |
bool | showTools, | ||
bool | internalizeToolBarsAndProgress, | ||
Directory * | directory, | ||
QWidget * | parent = 0 ) |
Create a scene widget.
References addTo(), addToPermanent(), cnetModified(), createControlPoint(), deleteControlPoint(), directory(), Isis::MosaicGraphicsView::enableResizeZooming(), getScene(), getView(), modifyControlPoint(), and queueSelectionChanged().
|
virtual |
|
slot |
References cubesChanged(), getView(), images(), refit(), Isis::ProgressBar::setText(), and Isis::toInt().
void Isis::MosaicSceneWidget::addTo | ( | QMenu * | menu | ) |
References Isis::MosaicTool::addTo().
Referenced by Isis::Footprint2DView::Footprint2DView(), and MosaicSceneWidget().
void Isis::MosaicSceneWidget::addTo | ( | QToolBar * | toolBar | ) |
References Isis::MosaicTool::addTo().
void Isis::MosaicSceneWidget::addTo | ( | ToolPad * | toolPad | ) |
References Isis::MosaicTool::addTo().
void Isis::MosaicSceneWidget::addToPermanent | ( | QToolBar * | toolBar | ) |
References Isis::Projection::Mapping().
Referenced by Isis::Footprint2DView::Footprint2DView(), and MosaicSceneWidget().
|
inline |
bool Isis::MosaicSceneWidget::blockSelectionChange | ( | bool | block | ) |
Referenced by Isis::MosaicSceneItem::cubeDisplayChanged(), and Isis::MosaicSceneItem::updateSelection().
|
signal |
Referenced by MosaicSceneWidget().
bool Isis::MosaicSceneWidget::contextMenuEvent | ( | QGraphicsSceneContextMenuEvent * | event | ) |
This is called by MosaicGraphicsScene::contextMenuEvent.
Return false if not handled, true if handled.
References Isis::ImageList::append(), getScene(), Isis::Directory::project(), selectedImages(), Isis::Directory::supportedActions(), and Isis::ImageList::supportedActions().
|
signal |
|
signal |
|
signal |
|
signal |
Referenced by MosaicSceneWidget().
QStringList Isis::MosaicSceneWidget::cubeFileNames | ( | ) |
Referenced by Isis::ControlNetGraphicsItem::buildChildren().
QRectF Isis::MosaicSceneWidget::cubesBoundingRect | ( | ) | const |
|
signal |
Referenced by addImages().
|
inline |
MosaicSceneItem * Isis::MosaicSceneWidget::cubeToMosaic | ( | Image * | image | ) |
References _FILEINFO_, cubeToMosaic(), Isis::Image::displayProperties(), and Isis::IException::Programmer.
Referenced by cubeToMosaic(), moveDownOne(), moveToBottom(), moveToTop(), moveUpOne(), moveZ(), removeImages(), and supportedActions().
|
signal |
Referenced by MosaicSceneWidget().
Directory * Isis::MosaicSceneWidget::directory | ( | ) | const |
void Isis::MosaicSceneWidget::enableRubberBand | ( | bool | enable | ) |
Referenced by Isis::MosaicZoomTool::updateTool().
|
protectedvirtual |
void Isis::MosaicSceneWidget::fromPvl | ( | const PvlObject & | project | ) |
Call this method after loading any cubes when loading a project.
project | The project Pvl |
References Isis::PvlObject::findGroup(), Isis::PvlObject::findObject(), Isis::PvlObject::hasObject(), setProjection(), and Isis::toDouble().
QProgressBar * Isis::MosaicSceneWidget::getProgress | ( | ) |
Referenced by Isis::ControlNetGraphicsItem::buildChildren().
|
inline |
Referenced by Isis::MosaicGridToolConfigDialog::applySettings(), Isis::MosaicGridTool::autoGrid(), Isis::MosaicGridTool::domainMaxLon(), Isis::MosaicGridTool::domainMinLon(), Isis::MosaicGridTool::fromPvl(), Isis::MosaicFindTool::getUserGroundPoint(), Isis::MosaicGridTool::latType(), Isis::MosaicGridTool::lonDomain(), Isis::MosaicSceneItem::MosaicSceneItem(), Isis::MosaicControlNetTool::mouseButtonRelease(), Isis::MosaicAreaTool::mouseButtonRelease(), Isis::MosaicFindTool::mouseButtonRelease(), Isis::MosaicGridTool::onProjectionChanged(), Isis::MosaicGridToolConfigDialog::readSettings(), Isis::MosaicSceneItem::reproject(), Isis::MosaicGridTool::setLatExtents(), Isis::MosaicGridTool::setLonExtents(), Isis::MosaicTrackTool::updateLabels(), and Isis::MosaicAreaTool::userChangedBox().
|
inline |
Referenced by Isis::MosaicAreaTool::clearBox(), Isis::MosaicGridTool::clearGrid(), Isis::MosaicFindTool::clearPoint(), contextMenuEvent(), Isis::MosaicGridTool::drawGrid(), eventFilter(), Isis::Footprint2DView::Footprint2DView(), Isis::MosaicFindTool::getUserGroundPoint(), MosaicSceneWidget(), Isis::MosaicControlNetTool::mouseButtonRelease(), Isis::MosaicFindTool::mouseButtonRelease(), selectedImages(), setOutlineRect(), and Isis::MosaicAreaTool::userChangedBox().
|
inline |
Referenced by addImages(), eventFilter(), Isis::ControlNetGraphicsItem::findClosestControlPoint(), Isis::Footprint2DView::Footprint2DView(), Isis::MosaicFindTool::getUserGroundPoint(), MosaicSceneWidget(), Isis::MosaicControlNetTool::mouseButtonRelease(), Isis::MosaicAreaTool::mouseButtonRelease(), Isis::MosaicFindTool::mouseButtonRelease(), Isis::MosaicZoomTool::mouseWheel(), Isis::MosaicGridTool::onCubesChanged(), refit(), Isis::MosaicZoomTool::rubberBandComplete(), save(), setOutlineRect(), toPvl(), Isis::MosaicZoomTool::updateResolutionBox(), Isis::MosaicPanTool::updateTool(), Isis::MosaicSelectTool::updateTool(), Isis::MosaicZoomTool::updateTool(), and Isis::MosaicAreaTool::userChangedBox().
ImageList Isis::MosaicSceneWidget::images | ( | ) |
References Isis::ImageList::append(), and images().
Referenced by addImages(), images(), moveDownOne(), moveToBottom(), moveToTop(), moveUpOne(), removeImages(), and supportedActions().
bool Isis::MosaicSceneWidget::isControlNetToolActive | ( | ) |
void Isis::MosaicSceneWidget::load | ( | XmlStackedHandlerReader * | xmlReader | ) |
|
signal |
Referenced by MosaicSceneWidget().
|
signal |
References moveDownOne(), moveToBottom(), moveToTop(), and moveUpOne().
|
signal |
Referenced by eventFilter().
|
signal |
Referenced by eventFilter().
|
signal |
Referenced by eventFilter().
|
signal |
Referenced by eventFilter().
|
signal |
Referenced by eventFilter().
|
signal |
Referenced by eventFilter().
|
signal |
Referenced by eventFilter().
double Isis::MosaicSceneWidget::moveDownOne | ( | Image * | image | ) |
References cubeToMosaic(), and moveDownOne().
References images(), and moveDownOne().
double Isis::MosaicSceneWidget::moveDownOne | ( | MosaicSceneItem * | item | ) |
References moveZ().
Referenced by mosCubeClosed(), moveDownOne(), and moveDownOne().
double Isis::MosaicSceneWidget::moveToBottom | ( | Image * | image | ) |
This doesn't compress the Z values - the original Z value of this image is guaranteed to be empty after this operation.
References cubeToMosaic(), and moveToBottom().
This doesn't compress the Z values - the original Z values of these images are guaranteed to be empty after this operation.
References images(), and moveToBottom().
double Isis::MosaicSceneWidget::moveToBottom | ( | MosaicSceneItem * | item | ) |
This doesn't compress the Z values - the original Z values of this scene item is guaranteed to be empty after this operation.
Referenced by mosCubeClosed(), moveToBottom(), and moveToBottom().
double Isis::MosaicSceneWidget::moveToTop | ( | Image * | image | ) |
This doesn't compress the Z values - the original Z value of this image is guaranteed to be empty after this operation.
References cubeToMosaic(), and moveToTop().
This doesn't compress the Z values - the original Z values of these images are guaranteed to be empty after this operation.
References images(), and moveToTop().
double Isis::MosaicSceneWidget::moveToTop | ( | MosaicSceneItem * | item | ) |
This doesn't compress the Z values - the original Z values of this scene item is guaranteed to be empty after this operation.
Referenced by mosCubeClosed(), moveToTop(), and moveToTop().
double Isis::MosaicSceneWidget::moveUpOne | ( | Image * | image | ) |
References cubeToMosaic(), and moveUpOne().
References images(), and moveUpOne().
double Isis::MosaicSceneWidget::moveUpOne | ( | MosaicSceneItem * | item | ) |
References moveZ().
Referenced by mosCubeClosed(), moveUpOne(), and moveUpOne().
double Isis::MosaicSceneWidget::moveZ | ( | Image * | image, |
double | newZ, | ||
bool | newZValueMightExist = true ) |
References cubeToMosaic(), and moveZ().
double Isis::MosaicSceneWidget::moveZ | ( | MosaicSceneItem * | sceneItem, |
double | newZ, | ||
bool | newZValueMightExist = true ) |
This method moves the given scene item to the given Z value.
By default, this does not create gaps in the Z-values and makes the necessary room/adjustments for the new item to go to it's spot. If the last operation was moveToTop or moveToBottom, because those methods don't compress/adjust the surrounding Z values, we can avoid any and all adjustments here (significant performance boost) by using newZValueMightExist=false.
N = # items in the scene The time complexity of this method is N if newZValueMightExist. The time complexity of this method is constant if !newZValueMightExist.
sceneItem | The item in this scene to change the Z value |
newZ | The new Z value for the item |
newZValueMightExist | True if an item in the scene might occupy the new Z value |
Referenced by moveDownOne(), moveUpOne(), moveZ(), and Isis::MosaicSceneWorkOrder::restoreZPositions().
|
signal |
Referenced by setProjection().
|
signal |
Referenced by MosaicSceneWidget().
|
slot |
This method refits t:he items in the graphics view.
References cubesBoundingRect(), and getView().
Referenced by addImages(), setOutlineRect(), and Isis::MosaicZoomTool::zoomFit().
|
slot |
References cubeToMosaic(), and images().
|
signal |
Referenced by eventFilter().
void Isis::MosaicSceneWidget::save | ( | QXmlStreamWriter & | stream, |
Project * | project, | ||
FileName | newProjectRoot ) const |
References getView(), Isis::Projection::Mapping(), Isis::PvlContainer::setName(), and Isis::toString().
Referenced by Isis::Footprint2DView::save().
ImageList Isis::MosaicSceneWidget::selectedImages | ( | ) |
Returns a list of all the cubes selected in the scene.
References Isis::ImageList::append(), getScene(), and selectedImages().
Referenced by contextMenuEvent(), and selectedImages().
|
slot |
References Isis::MosaicSceneItem::scenePropertiesChanged().
Referenced by Isis::MosaicPanTool::updateTool(), and Isis::MosaicZoomTool::updateTool().
|
slot |
References getScene(), getView(), and refit().
|
slot |
|
inline |
Return an empty list of actions for unknown data types.
Get a list of actions this scene can perform given "images".
References cubeToMosaic(), images(), and Isis::Directory::project().
PvlObject Isis::MosaicSceneWidget::toPvl | ( | ) | const |
|
inline |
Referenced by Isis::MosaicSceneItem::MosaicSceneItem().
|
signal |