Isis Developer Reference
Footprint2DView.h
Go to the documentation of this file.
1 #ifndef Footprint2DView_h
2 #define Footprint2DView_h
3 
10 /* SPDX-License-Identifier: CC0-1.0 */
11 
12 #include <QList>
13 #include <QMap>
14 #include <QSize>
15 
17 #include "FileName.h"
18 #include "ImageList.h"
19 #include "XmlStackedHandler.h"
20 
21 class QAction;
22 class QEvent;
23 class QMainWindow;
24 class QToolBar;
25 class QWidgetAction;
26 class QXmlStreamWriter;
27 
28 namespace Isis {
29 
30  class ControlPoint;
31  class Directory;
32  class Image;
33  class ImageFileListWidget;
34  class MosaicSceneWidget;
35  class Project;
36  class ToolPad;
37  class XmlStackedHandlerReader;
38 
103 
104  Q_OBJECT
105 
106  public:
107  Footprint2DView(Directory *directory, QWidget *parent=0);
109 
112 
113  void load(XmlStackedHandlerReader *xmlReader);
114  void save(QXmlStreamWriter &stream, Project *project, FileName newProjectRoot) const;
115 
116  signals:
117  void modifyControlPoint(ControlPoint *controlPoint);
118  void deleteControlPoint(ControlPoint *controlPoint);
119  void createControlPoint(double latitude, double longitude);
120 
122  void controlPointAdded(QString newPointId);
123 
124  public slots:
125  void enableControlNetTool(bool value);
126 
127  protected:
128  bool eventFilter(QObject *watched, QEvent *event);
129 
130  private slots:
131  void onItemAdded(ProjectItem *item);
132  void onItemsAdded();
133  void onItemRemoved(ProjectItem *item);
134  void onQueueSelectionChanged();
135  void onMosItemRemoved(Image *image);
136 
137  private:
138  void enableActions();
139 
145  class XmlHandler : public XmlStackedHandler {
146  public:
147  XmlHandler(Footprint2DView *footprintView);
148  ~XmlHandler();
149 
150  virtual bool startElement(const QString &namespaceURI, const QString &localName,
151  const QString &qName, const QXmlAttributes &atts);
152  virtual bool endElement(const QString &namespaceURI, const QString &localName,
153  const QString &qName);
154 
155  private:
156  Q_DISABLE_COPY(XmlHandler);
157 
158  Footprint2DView *m_footprintView;
159  };
160 
161  private:
162  MosaicSceneWidget *m_sceneWidget;
163  ImageFileListWidget *m_fileListWidget;
164  QMainWindow *m_window;
165  ImageList m_images;
166  QMap<Image *, ProjectItem *> m_imageItemMap;
167  Directory *m_directory;
168 
169  QToolBar *m_permToolBar;
170  QToolBar *m_activeToolBar;
171  ToolPad *m_toolPad;
172  };
173 }
174 
175 #endif
AbstractProjectItemView.h
ProjectItem.h
FileName.h
Isis::MosaicSceneWidget::getView
MosaicGraphicsView * getView() const
Definition: MosaicSceneWidget.h:162
QWidget
Cube.h
Isis::Directory
Definition: Directory.h:271
Isis::AbstractProjectItemView
AbstractProjectItemView is a base class for views of a ProjectItemModel in Qt's model-view framework.
Definition: AbstractProjectItemView.h:79
Isis::Footprint2DView
View for displaying footprints of images in a QMos like way.
Definition: Footprint2DView.h:102
MosaicSceneWidget.h
Project.h
Isis::ImageFileListWidget::save
void save(QXmlStreamWriter &stream, Project *project, FileName newProjectRoot) const
This method saves the FootprintColumns in the project and the settings associated with every column.
Definition: ImageFileListWidget.cpp:626
ImageFileListWidget.h
MosaicControlNetTool.h
Isis::ProjectItem::image
Image * image() const
Returns the Image stored in the data of the item.
Definition: ProjectItem.cpp:476
Isis::AbstractProjectItemView::dropEvent
virtual void dropEvent(QDropEvent *event)
Drops the data into the internal model if it can accept the data.
Definition: AbstractProjectItemView.cpp:148
Isis::FileName
File name manipulation and expansion.
Definition: FileName.h:100
Isis::Footprint2DView::deleteControlPoint
void deleteControlPoint(ControlPoint *controlPoint)
Isis::ImageFileListWidget::removeImages
void removeImages(ImageList *images)
Removes an imagelist from the FileListWidget.
Definition: ImageFileListWidget.cpp:446
Isis::XmlStackedHandlerReader::pushContentHandler
virtual void pushContentHandler(XmlStackedHandler *newHandler)
Push a contentHandler and maybe continue parsing...
Definition: XmlStackedHandlerReader.cpp:55
Directory.h
Isis::ImageFileListWidget
A colored, grouped cube list.
Definition: ImageFileListWidget.h:64
Isis::ProjectItem::shape
Shape * shape() const
Returns the Shape stored in the data of the item.
Definition: ProjectItem.cpp:496
Isis::ImageFileListWidget::addImages
void addImages(ImageList *images)
This method adds the new images to the tree.
Definition: ImageFileListWidget.cpp:342
QMainWindow
Isis::ProjectItemModel::selectionModel
QItemSelectionModel * selectionModel()
Returns the internal selection model.
Definition: ProjectItemModel.cpp:93
Isis::MosaicControlNetTool::loadNetwork
void loadNetwork()
Load m_controlNetFile into memory - this will re-load the network if it's already open.
Definition: MosaicControlNetTool.cpp:610
Isis::ImageList::append
void append(Image *const &value)
Appends an image to the image list.
Definition: ImageList.cpp:153
Isis::Footprint2DView::Footprint2DView
Footprint2DView(Directory *directory, QWidget *parent=0)
Constructor.
Definition: Footprint2DView.cpp:54
Isis::Shape::footprint
geos::geom::MultiPolygon * footprint()
Get the footprint of this shape (if available).
Definition: Shape.cpp:394
Isis::MosaicSceneWidget
This widget encompasses the entire mosaic scene.
Definition: MosaicSceneWidget.h:153
Isis::XmlStackedHandler::startElement
virtual bool startElement(const QString &namespaceURI, const QString &localName, const QString &qName, const QXmlAttributes &atts)
Definition: XmlStackedHandler.cpp:44
Isis::Project::activeControl
Control * activeControl()
Return the Active Control (control network)
Definition: Project.cpp:1903
Isis::Directory::project
Project * project() const
Gets the Project for this directory.
Definition: Directory.cpp:1311
Image.h
Isis::MosaicSceneWidget::addImages
void addImages(ImageList)
Definition: MosaicSceneWidget.cpp:1356
ToolPad.h
Isis::Shape::cube
Cube * cube()
Get the Cube * associated with this display property.
Definition: Shape.cpp:324
Isis::ProjectItem::isShape
bool isShape() const
Returns true if an Shape is stored in the data of the item.
Definition: ProjectItem.cpp:668
QToolBar
Isis::XmlStackedHandlerReader
Manage a stack of content handlers for reading XML files.
Definition: XmlStackedHandlerReader.h:30
Shape.h
Isis::Project
The main project for ipce.
Definition: Project.h:289
Isis::MosaicSceneWidget::getScene
QGraphicsScene * getScene() const
Definition: MosaicSceneWidget.h:166
Isis::ImageList
Internalizes a list of images and allows for operations on the entire list.
Definition: ImageList.h:55
Isis::Footprint2DView::enableControlNetTool
void enableControlNetTool(bool value)
A slot function that is called when directory emits a siganl that an active control network is set.
Definition: Footprint2DView.cpp:320
Isis::MosaicSceneWidget::addTo
void addTo(QMenu *menu)
Definition: MosaicSceneWidget.cpp:421
Isis::ControlPoint
A single control point.
Definition: ControlPoint.h:354
Isis::Shape::id
QString id() const
Get a unique, identifying string associated with this shape.
Definition: Shape.cpp:459
Isis::Footprint2DView::save
void save(QXmlStreamWriter &stream, Project *project, FileName newProjectRoot) const
Save the footprint view widgets (ImageFileListWidget and MosaicSceneWidget to an XML file.
Definition: Footprint2DView.cpp:366
Isis::AbstractProjectItemView::dragEnterEvent
virtual void dragEnterEvent(QDragEnterEvent *event)
Accepts the drag enter event if the internal model can accept the mime data.
Definition: AbstractProjectItemView.cpp:119
Isis::Footprint2DView::controlPointAdded
void controlPointAdded(QString newPointId)
Isis::ProjectItem::isImage
bool isImage() const
Returns true if an Image is stored in the data of the item.
Definition: ProjectItem.cpp:646
Isis::AbstractProjectItemView::internalModel
virtual ProjectItemModel * internalModel()
Returns the internal model of the view.
Definition: AbstractProjectItemView.cpp:108
Isis::Footprint2DView::createControlPoint
void createControlPoint(double latitude, double longitude)
Isis::Footprint2DView::eventFilter
bool eventFilter(QObject *watched, QEvent *event)
Event filter to filter out drag and drop events.
Definition: Footprint2DView.cpp:178
Isis::AbstractProjectItemView::dragMoveEvent
virtual void dragMoveEvent(QDragMoveEvent *event)
Accepts the drag event if the internal model can accept the mime data.
Definition: AbstractProjectItemView.cpp:134
MosaicGraphicsView.h
ControlPoint.h
ProjectItemModel.h
ImageList.h
Isis::MosaicSceneWidget::addToPermanent
void addToPermanent(QToolBar *toolBar)
Definition: MosaicSceneWidget.cpp:379
Isis::XmlStackedHandler::endElement
virtual bool endElement(const QString &namespaceURI, const QString &localName, const QString &qName)
Definition: XmlStackedHandler.cpp:55
Isis::Image
This represents a cube in a project-based GUI interface.
Definition: Image.h:107
Isis::MosaicSceneWidget::selectedImages
ImageList selectedImages()
Returns a list of all the cubes selected in the scene.
Definition: MosaicSceneWidget.cpp:742
Isis::ToolPad
Definition: ToolPad.h:14
Footprint2DView.h
Isis::Footprint2DView::mosaicSceneWidget
MosaicSceneWidget * mosaicSceneWidget()
Accessor for the MosaicSceneWidget.
Definition: Footprint2DView.cpp:157
Isis::MosaicSceneWidget::removeImages
void removeImages(ImageList)
Definition: MosaicSceneWidget.cpp:1408
Isis::Footprint2DView::redrawMeasures
void redrawMeasures()
Isis::MosaicControlNetTool
//TODO: Remove debug printout & comment // 2016-08-25 Tracie Sucharski - Checking Directory pointer f...
Definition: MosaicControlNetTool.h:74
Isis::Footprint2DView::modifyControlPoint
void modifyControlPoint(ControlPoint *controlPoint)
Isis::MosaicGraphicsView
A graphics view that resizes in a more friendly way.
Definition: MosaicGraphicsView.h:19
Isis::XmlStackedHandler
XML Handler that parses XMLs in a stack-oriented way.
Definition: XmlStackedHandler.h:118
Isis::AbstractProjectItemView::disableActions
virtual void disableActions()
Disables toolbars and toolpad actions.
Definition: AbstractProjectItemView.cpp:196
Isis::Footprint2DView::~Footprint2DView
~Footprint2DView()
Destructor.
Definition: Footprint2DView.cpp:142
QMap
This is free and unencumbered software released into the public domain.
Definition: CubeIoHandler.h:22
QObject
Isis::Footprint2DView::fileListWidget
ImageFileListWidget * fileListWidget()
Accessor for the FileListWidget.
Definition: Footprint2DView.cpp:165
ControlNetTool.h
Isis::Footprint2DView::load
void load(XmlStackedHandlerReader *xmlReader)
Loads the Footprint2DView from an XML file.
Definition: Footprint2DView.cpp:351
IsisDebug.h
QAction
QDockWidget
XmlStackedHandlerReader.h
XmlStackedHandler.h
Isis::MosaicSceneWidget::save
void save(QXmlStreamWriter &stream, Project *project, FileName newProjectRoot) const
Definition: MosaicSceneWidget.cpp:627
Isis
This is free and unencumbered software released into the public domain.
Definition: Apollo.h:16
Isis::ProjectItem
Represents an item of a ProjectItemModel in Qt's model-view framework.
Definition: ProjectItem.h:134