Isis 3 Programmer Reference
|
Display nomenclature on MDI Cube Viewports. More...
#include <FeatureNomenclatureTool.h>
Classes | |
class | FeatureDisplayPosition |
A named feature's position in a viewport. More... | |
class | FeaturePosition |
A named feature's position in a cube. More... | |
class | ViewportFeatureDisplay |
The feature display on a single viewport. More... | |
Public Types | |
enum | VectorType { None, Arrows4, Arrows8, Box } |
Enumeration of extent vector typess. More... | |
Public Slots | |
void | activate (bool) |
Activates the tool. More... | |
void | setCubeViewport (MdiCubeViewport *cvp) |
Sets the current viewport to the given cvp. More... | |
Signals | |
void | clearWarningSignal () |
void | toolActivated () |
void | viewportChanged () |
Public Member Functions | |
FeatureNomenclatureTool (QWidget *parent) | |
This instantiates a FeatureNomenclatureTool. More... | |
~FeatureNomenclatureTool () | |
Cleans up memory allocated by this tool. More... | |
void | addTo (QMenu *menu) |
Add the 'Show Nomenclature' option to the options menu. More... | |
void | paintViewport (MdiCubeViewport *vp, QPainter *painter) |
Paint features on the given viewport. More... | |
bool | defaultEnabled () const |
Is this tool enabled by default? (i.e. More... | |
QColor | fontColor () const |
What is the font color to use? More... | |
int | fontSize () const |
Retrieve the font size of the features in this tool. More... | |
bool | showApprovedOnly () const |
Show approved features only? More... | |
VectorType | vectorType () const |
Draw vectors to the extents of features? More... | |
void | setDefaultEnabled (bool defaultEnabled) |
Set whether this tool is enabled by default. More... | |
void | setFontColor (QColor color) |
Set the color to use for drawing on the viewport. More... | |
void | setFontSize (int newFontSize) |
Set the font point size to use for drawing text on the viewport. More... | |
void | setShowApprovedOnly (bool approvedOnly) |
Set whether to show approved features and exclude unapproved features. More... | |
void | setVectorType (VectorType show) |
Set whether to draw vectors from the feature center to the feature extents on the viewport. More... | |
QString | menuName () const |
This is the name of the menu that should be passed into "addTo()". More... | |
void | addTo (ViewportMainWindow *mw) |
Adds the tool to the application. More... | |
void | addTo (ToolPad *toolpad) |
Adds the tool to the toolpad. More... | |
virtual void | addTo (Workspace *ws) |
Adds the given workspace to the cubeviewport list. More... | |
virtual void | addToPermanent (QToolBar *toolbar) |
void | addToActive (QToolBar *toolbar) |
QString | toolIconDir () const |
returns the path to the icon directory. More... | |
RubberBandTool * | rubberBandTool () |
void | setList (ToolList *currentList) |
Protected Types | |
typedef QVector< MdiCubeViewport *> | CubeViewportList |
A list of cubeviewports. More... | |
Protected Slots | |
virtual void | rubberBandComplete () |
virtual void | screenPixelsChanged () |
This is called when actions change which pixels from the cube are displayed. More... | |
virtual void | mouseEnter () |
virtual void | mouseMove (QPoint p) |
virtual void | mouseMove (QPoint p, Qt::MouseButton) |
virtual void | mouseLeave () |
Protected Member Functions | |
QWidget * | createToolBarWidget (QStackedWidget *parent) |
Creates the widget that goes on the tool bar when this tool is active. More... | |
QAction * | toolPadAction (ToolPad *pad) |
Add this tool's action to the toolpad. More... | |
void | mouseButtonRelease (QPoint p, Qt::MouseButton s) |
This handles a mouse release on one of the cube viewports when this tool is active. More... | |
void | updateTool () |
Updates the state of the current tool. More... | |
virtual void | mouseDoubleClick (QPoint p) |
virtual void | mouseButtonPress (QPoint p, Qt::MouseButton s) |
virtual void | updateMeasure () |
virtual void | scaleChanged () |
virtual void | stretchRequested (MdiCubeViewport *, int) |
void | registerTool (MdiCubeViewport *viewport) |
Registers the tool to the viewport. More... | |
MdiCubeViewport * | cubeViewport () const |
Return the current cubeviewport. More... | |
CubeViewportList * | cubeViewportList () const |
Return the list of cubeviewports. More... | |
virtual void | addConnections (MdiCubeViewport *cvp) |
Anytime a tool is created, you must add the connections for it. More... | |
virtual void | removeConnections (MdiCubeViewport *cvp) |
Anytime a tool is created, you must be able to remove it's connections. More... | |
virtual void | enableRubberBandTool () |
Anytime a tool is created, you may use the rubber band tool. More... | |
Workspace * | workspace () |
Private Slots | |
void | centerOnSelectedFeature () |
Center the relevent viewport (and any viewports linked to it) on the feature selected in the feature selection combo box. More... | |
void | configure () |
Give a configuration dialog for the options available in this tool. More... | |
void | featureSelected () |
This handles a feature being selected in the feature list combo box. More... | |
void | featuresIdentified (FeatureNomenclature *) |
A feature nomenclature has finished querying... More... | |
void | findNomenclatureStateChanged (int) |
The 'Name Features' check box has changed state. More... | |
void | nomenclaturePositionsOutdated () |
Update the screen coordinates of the named features because the viewport has changed it's mappings. More... | |
void | onToolActivated () |
When this tool is activated (clicked on in the tool bar), turn ourselves on immediately. More... | |
void | showDisclaimer () |
Show the user our nomenclature disclaimer and make note that we have shown the disclaimer. More... | |
Private Member Functions | |
void | centerOnFeature (MdiCubeViewport *vp, FeatureNomenclature::Feature) |
Center the given and any linked viewports (which contain the same feature) on the given feature. More... | |
void | featuresForViewportFound (MdiCubeViewport *vp) |
Move the features from a searching state to a found state for the given viewport. More... | |
void | findMissingNomenclature () |
Update this tool's nomenclature data based on this tool's enabled state and the current viewport list. More... | |
void | findMissingNomenclature (MdiCubeViewport *vp) |
Query for nomenclature on the given viewport. More... | |
void | rebuildFeaturesCombo () |
Rebuild m_foundFeaturesCombo's data from scratch. More... | |
void | removeFeatureDisplay (MdiCubeViewport *vp) |
Remove knowledge of features on the given viewport. More... | |
void | showFeatureDetails (FeatureNomenclature::Feature) |
Show a dialog with full feature details of a given feature. More... | |
void | showFeatureWebsite (FeatureNomenclature::Feature) |
Show a web view pointed to the feature's web page. More... | |
void | toolStateChanged () |
This should be called any time this tool's enabled or searching state could have changed. More... | |
void | viewportDone (MdiCubeViewport *vp) |
Finalize the search results for the given viewport. More... | |
ViewportFeatureDisplay * | viewportFeatureDisplay (MdiCubeViewport *vp) |
Map from viewport to feature display. More... | |
const ViewportFeatureDisplay * | viewportFeatureDisplay (MdiCubeViewport *vp) const |
Map from viewport to feature display. More... | |
bool | viewportFeaturesFound (MdiCubeViewport *vp) const |
Test if features have already been found for a given viewport. More... | |
QList< MdiCubeViewport * > | viewportsWithFoundNomenclature () |
Get a list of viewports with found nomenclature. More... | |
void | readSettings () |
Read this tool's preserved state. More... | |
void | writeSettings () |
Write out this tool's preserved state between runs. More... | |
Private Attributes | |
QPointer< QAction > | m_action |
This is the 'Show Nomenclature' toggleable action in the options menu. More... | |
QPointer< QCheckBox > | m_findNomenclatureCheckBox |
This is the 'Name Features' check box when this tool is active. More... | |
QPointer< QComboBox > | m_foundFeaturesCombo |
This combo box lists all of the found features and their viewports. More... | |
QPointer< QPushButton > | m_nomenclatureCenterBtn |
This is the 'Center' button in this tool's tool bar. More... | |
QPointer< QPushButton > | m_nomenclatureOptionsBtn |
This is the 'Tool Options' button in this tool's tool bar. More... | |
QPointer< QPushButton > | m_disclaimerBtn |
This is the 'Disclaimer' button in this tool's tool bar. More... | |
QPointer< QProgressBar > | m_queryingProgress |
This is a busy indicator that is visible when queries are out to the nomenclature database. More... | |
QList< ViewportFeatureDisplay > * | m_foundNomenclature |
The nomenclature that has been identified, one for each viewport. More... | |
QMap< MdiCubeViewport *, FeatureNomenclature * > * | m_nomenclatureSearchers |
The nomenclature being queried currently, one for each viewport that has no found nomenclature. More... | |
bool | m_nomenclatureEnabled |
Do we find and display nomenclature? This corresponds to the 'Name Features' check box and the 'Show Nomenclature' action in the options menu. More... | |
QString | m_disclaimerText |
The (HTML) contents of the disclaimer to show the user. More... | |
int | m_fontSize |
The font size to use when naming features. More... | |
QColor * | m_fontColor |
The color to use when drawing on the viewport. More... | |
bool | m_defaultEnabled |
Do we turn ourselves on immediately? More... | |
bool | m_disclaimedAlready |
Have we ever shown the user our disclaimer? More... | |
VectorType | m_extentType |
How we need to draw extents (if at all) More... | |
bool | m_showApprovedOnly |
Only show IAU approved features. More... | |
Display nomenclature on MDI Cube Viewports.
This tool is designed to paint named features onto the viewports' displays. The nomenclature and it's positioning comes from the FeatureNomenclature class. Options such as auto-enabling from program start, showing vectors, font configurations, showing detailed feature information and linking back to the nomenclature website are built-in.
2012-06-12 Steven Lambright and Kimberly Oyama - Implemented multiple extent types (Box, 4 Arrows, 8 Arrows). Added ability to hide unapproved or dropped features. Added appropriate mutators and accessors (showApprovedOnly(), vectorType(), setShowApprovedOnly(), setVectorType()). Added an enumerator for the vector types. Fixes #852. Fixes #892.
2012-06-26 Kimberly Oyama - Minor refactoring in the findMissingNomenclature() method. References #958.
2012-07-06 Debbie A. Cook, Updated Spice members to be more compliant with Isis coding standards. References #972
2012-10-11 Debbie A. Cook, Updated to use new Target class. References Mantis tickets #775 and #1114.
2016-06-21 Kris Becker - Properly forward declare QPair as struct not class
Definition at line 56 of file FeatureNomenclatureTool.h.
|
protectedinherited |
Enumeration of extent vector typess.
Definition at line 62 of file FeatureNomenclatureTool.h.
Isis::FeatureNomenclatureTool::FeatureNomenclatureTool | ( | QWidget * | parent | ) |
This instantiates a FeatureNomenclatureTool.
This will read this tool's saved settings and potentially automatically enable itself.
parent |
Definition at line 46 of file FeatureNomenclatureTool.cpp.
References m_defaultEnabled, m_disclaimedAlready, m_disclaimerBtn, m_disclaimerText, m_extentType, m_findNomenclatureCheckBox, m_fontColor, m_fontSize, m_foundFeaturesCombo, m_foundNomenclature, m_nomenclatureCenterBtn, m_nomenclatureEnabled, m_nomenclatureOptionsBtn, m_nomenclatureSearchers, m_queryingProgress, m_showApprovedOnly, None, onToolActivated(), and readSettings().
Isis::FeatureNomenclatureTool::~FeatureNomenclatureTool | ( | ) |
Cleans up memory allocated by this tool.
Definition at line 98 of file FeatureNomenclatureTool.cpp.
References m_foundNomenclature, and m_nomenclatureSearchers.
|
slotinherited |
Activates the tool.
on |
Definition at line 131 of file Tool.cpp.
References Isis::Tool::addViewportConnections(), Isis::Tool::disableToolBar(), Isis::Tool::enableToolBar(), Isis::Tool::m_active, Isis::Tool::m_toolPadAction, and Isis::Tool::removeViewportConnections().
Referenced by Isis::Tool::addTo(), Isis::AdvancedTrackTool::AdvancedTrackTool(), Isis::RubberBandTool::disable(), Isis::RubberBandTool::enable(), Isis::AdvancedTrackTool::eventFilter(), Isis::FileTool::FileTool(), Isis::RubberBandTool::RubberBandTool(), Isis::TrackTool::TrackTool(), Isis::WindowTool::WindowTool(), and Isis::Workspace::Workspace().
|
inlineprotectedvirtualinherited |
Anytime a tool is created, you must add the connections for it.
cvp |
Reimplemented in Isis::TrackTool, and Isis::WindowTool.
Definition at line 253 of file Tool.h.
Referenced by Isis::Tool::addViewportConnections().
|
inherited |
Adds the tool to the application.
pViewPortMnWin |
Definition at line 78 of file Tool.cpp.
References Isis::ViewportMainWindow::activeToolBar(), Isis::Tool::addToActive(), Isis::Tool::addToPermanent(), Isis::ViewportMainWindow::getMenu(), Isis::Tool::menuName(), Isis::ViewportMainWindow::permanentToolBar(), Isis::ViewportMainWindow::toolPad(), and Isis::ViewportMainWindow::workspace().
Referenced by Isis::WindowTool::addTo(), Isis::SpecialPixelTool::addTo(), Isis::FileTool::addTo(), Isis::EditTool::addTo(), Isis::ViewportMainWindow::ViewportMainWindow(), and Isis::Workspace::Workspace().
|
inherited |
Adds the tool to the toolpad.
toolpad |
Definition at line 98 of file Tool.cpp.
References Isis::Tool::activate(), Isis::ToolPad::addAction(), Isis::Tool::m_toolPadAction, and Isis::Tool::toolPadAction().
|
virtual |
Add the 'Show Nomenclature' option to the options menu.
menu | Menu to add 'Show Nomenclature' to. |
Reimplemented from Isis::Tool.
Definition at line 116 of file FeatureNomenclatureTool.cpp.
References m_action, m_findNomenclatureCheckBox, and m_nomenclatureEnabled.
|
virtualinherited |
Adds the given workspace to the cubeviewport list.
ws |
Reimplemented in Isis::EditTool, Isis::FileTool, Isis::SpecialPixelTool, and Isis::WindowTool.
Definition at line 45 of file Tool.cpp.
References Isis::Tool::registerTool(), and Isis::Tool::setCubeViewport().
|
inherited |
toolbar |
Definition at line 112 of file Tool.cpp.
References Isis::Tool::createToolBarWidget(), Isis::Tool::disableToolBar(), and Isis::Tool::m_toolBarWidget.
Referenced by Isis::Tool::addTo(), and Isis::Workspace::Workspace().
|
inlinevirtualinherited |
toolbar |
Reimplemented in Isis::AdvancedTrackTool, Isis::FileTool, Isis::HelpTool, Isis::SpecialPixelTool, Isis::BlinkTool, and Isis::WindowTool.
Definition at line 111 of file Tool.h.
Referenced by Isis::Tool::addTo(), and Isis::Workspace::Workspace().
|
private |
Center the given and any linked viewports (which contain the same feature) on the given feature.
This also prioritizes the feature to display on top of the other features in the viewport(s) which center on the feature.
vp | The viewport to center (and to use for finding linked viewports) |
feature | The feature to center on the viewport |
Definition at line 550 of file FeatureNomenclatureTool.cpp.
References Isis::FeatureNomenclatureTool::ViewportFeatureDisplay::centerFeature(), Isis::MdiCubeViewport::isLinked(), viewportFeatureDisplay(), and viewportsWithFoundNomenclature().
Referenced by centerOnSelectedFeature(), and Isis::FeatureNomenclatureTool::ViewportFeatureDisplay::handleMouseClicked().
|
privateslot |
Center the relevent viewport (and any viewports linked to it) on the feature selected in the feature selection combo box.
Definition at line 413 of file FeatureNomenclatureTool.cpp.
References centerOnFeature(), and m_foundFeaturesCombo.
Referenced by createToolBarWidget().
|
privateslot |
Give a configuration dialog for the options available in this tool.
Definition at line 432 of file FeatureNomenclatureTool.cpp.
Referenced by createToolBarWidget().
|
protectedvirtual |
Creates the widget that goes on the tool bar when this tool is active.
parent |
Reimplemented from Isis::Tool.
Definition at line 303 of file FeatureNomenclatureTool.cpp.
References centerOnSelectedFeature(), configure(), featureSelected(), findNomenclatureStateChanged(), m_disclaimerBtn, m_findNomenclatureCheckBox, m_foundFeaturesCombo, m_nomenclatureCenterBtn, m_nomenclatureEnabled, m_nomenclatureOptionsBtn, m_queryingProgress, and showDisclaimer().
|
inlineprotectedinherited |
Return the current cubeviewport.
Definition at line 211 of file Tool.h.
References Isis::Tool::m_cvp.
Referenced by Isis::WindowTool::addConnections(), Isis::TrackTool::addConnections(), Isis::StretchTool::advancedStretchChanged(), Isis::FindTool::centerLinkedViewports(), Isis::StretchTool::changeStretch(), Isis::BandTool::changeView(), Isis::BandTool::copyLinkedViewports(), Isis::FileTool::discard(), Isis::Tool::enableToolBar(), Isis::FileTool::exportToList(), Isis::FileTool::exportView(), Isis::StatisticsTool::getStatistics(), Isis::FindTool::handleRecordClicked(), Isis::EditTool::LineToPoints(), Isis::TrackTool::locateCursor(), Isis::SunShadowTool::mouseButtonPress(), Isis::ControlNetTool::mouseButtonRelease(), Isis::RubberBandTool::mouseButtonRelease(), Isis::EditTool::mouseButtonRelease(), mouseButtonRelease(), Isis::FindTool::mouseButtonRelease(), Isis::StretchTool::mouseButtonRelease(), Isis::MatchTool::mouseButtonRelease(), Isis::QnetTool::mouseButtonRelease(), Isis::AdvancedTrackTool::mouseLeave(), Isis::ScatterPlotTool::mouseMove(), Isis::SunShadowTool::mouseMove(), Isis::TrackTool::mouseMove(), Isis::RubberBandTool::mouseMove(), Isis::SunShadowTool::paintViewport(), Isis::RubberBandTool::paintViewport(), Isis::FindTool::paintViewport(), Isis::FileTool::print(), Isis::SunShadowTool::recalculateShadowHeight(), Isis::EditTool::redoEdit(), Isis::FindTool::refresh(), Isis::HistogramTool::refreshPlot(), Isis::SpatialPlotTool::refreshPlot(), Isis::SpectralPlotTool::refreshPlot(), Isis::WindowTool::removeConnections(), Isis::TrackTool::removeConnections(), Isis::RubberBandTool::repaint(), Isis::WindowTool::resizeWindows(), Isis::HistogramTool::rubberBandComplete(), Isis::MeasureTool::rubberBandComplete(), Isis::ZoomTool::rubberBandComplete(), Isis::EditTool::rubberBandComplete(), Isis::StretchTool::rubberBandComplete(), Isis::FileTool::save(), Isis::FileTool::saveAs(), Isis::FileTool::saveAsCubeByOption(), Isis::FileTool::saveAsReducedCube(), Isis::FileTool::saveInfo(), Isis::BandTool::setBandBin(), Isis::BandTool::setList(), Isis::StretchTool::setStretchAcrossBands(), Isis::StretchTool::setStretchAllViewports(), Isis::StretchTool::showAdvancedDialog(), Isis::ScatterPlotTool::showNewScatterPlotConfig(), Isis::StretchTool::stretchChanged(), Isis::StretchTool::stretchGlobal(), Isis::StretchTool::stretchGlobalAllBands(), Isis::StretchTool::stretchRegional(), Isis::EditTool::undoEdit(), Isis::StretchTool::updateAdvStretchDialogforAll(), Isis::StretchTool::updateHistograms(), Isis::TrackTool::updateLabels(), Isis::MeasureTool::updateMeasure(), Isis::AdvancedTrackTool::updateRow(), Isis::WindowTool::updateTool(), Isis::BlinkTool::updateTool(), Isis::SpecialPixelTool::updateTool(), Isis::BandTool::updateTool(), Isis::SunShadowTool::updateTool(), Isis::AbstractPlotTool::updateTool(), Isis::ZoomTool::updateTool(), Isis::FileTool::updateTool(), Isis::EditTool::updateTool(), Isis::FindTool::updateTool(), Isis::StretchTool::updateTool(), Isis::AbstractPlotTool::viewportsToPlot(), Isis::EditTool::writeToCube(), Isis::ZoomTool::zoomBy(), Isis::ZoomTool::zoomFit(), Isis::ZoomTool::zoomFitHeight(), Isis::ZoomTool::zoomFitWidth(), and Isis::ZoomTool::zoomManual().
|
protectedinherited |
Return the list of cubeviewports.
Definition at line 390 of file Tool.cpp.
References Isis::Workspace::cubeViewportList().
Referenced by Isis::BlinkTool::advance(), Isis::SpecialPixelTool::apply(), Isis::FindTool::centerLinkedViewports(), Isis::WindowTool::changeCursor(), Isis::FileTool::closeAll(), Isis::BandTool::copyAllViewports(), Isis::BandTool::copyLinkedViewports(), Isis::MatchTool::createPoint(), Isis::BlinkTool::eventFilter(), featuresIdentified(), findMissingNomenclature(), findNomenclatureStateChanged(), Isis::FindTool::handleLinkClicked(), Isis::WindowTool::linkWindows(), Isis::RubberBandTool::mouseButtonRelease(), Isis::RubberBandTool::mouseMove(), Isis::QnetTool::openGround(), Isis::StereoTool::paintAllViewports(), Isis::ControlNetTool::paintAllViewports(), Isis::MatchTool::paintAllViewports(), Isis::QnetTool::paintAllViewports(), Isis::FindTool::refresh(), Isis::ScatterPlotTool::repaintViewports(), Isis::AbstractPlotTool::repaintViewports(), Isis::WindowTool::resizeWindows(), Isis::BlinkTool::reverse(), Isis::ZoomTool::rubberBandComplete(), Isis::MatchTool::serialNumberList(), Isis::ControlNetTool::setControlNet(), setFontColor(), setFontSize(), setShowApprovedOnly(), Isis::StretchTool::setStretchAllViewports(), setVectorType(), Isis::StretchTool::stretchGlobalAllViewports(), Isis::BlinkTool::toggleLink(), Isis::WindowTool::unlinkWindows(), Isis::MeasureTool::updateMeasure(), Isis::AdvancedTrackTool::updateRow(), Isis::WindowTool::updateTool(), Isis::BlinkTool::updateTool(), Isis::FindTool::updateTool(), Isis::AbstractPlotTool::viewportsToPlot(), Isis::ZoomTool::zoomBy(), Isis::ZoomTool::zoomFit(), Isis::ZoomTool::zoomFitHeight(), Isis::ZoomTool::zoomFitWidth(), and Isis::ZoomTool::zoomManual().
bool Isis::FeatureNomenclatureTool::defaultEnabled | ( | ) | const |
Is this tool enabled by default? (i.e.
on program start)
Definition at line 151 of file FeatureNomenclatureTool.cpp.
References m_defaultEnabled.
Referenced by Isis::NomenclatureToolConfigDialog::readSettings(), and setDefaultEnabled().
|
protectedvirtualinherited |
Anytime a tool is created, you may use the rubber band tool.
Enable the use of the rubberband tool.
Reimplemented in Isis::RubberBandTool, Isis::ZoomTool, Isis::MeasureTool, Isis::StereoTool, Isis::SpatialPlotTool, Isis::SpectralPlotTool, and Isis::HistogramTool.
Definition at line 339 of file Tool.cpp.
References Isis::RubberBandTool::disable().
Referenced by Isis::Tool::addViewportConnections().
|
privateslot |
This handles a feature being selected in the feature list combo box.
The 'Center' button's enabled state is set to reflect if a feature is selected and the tool is enabled.
Definition at line 447 of file FeatureNomenclatureTool.cpp.
References m_foundFeaturesCombo, m_nomenclatureCenterBtn, and m_nomenclatureEnabled.
Referenced by createToolBarWidget(), and toolStateChanged().
|
private |
Move the features from a searching state to a found state for the given viewport.
The FeatureNomenclature class must have emitted featuresIdentified before calling this. The viewport must be a valid pointer.
vp | The viewport which we're changing the nomenclature state of. |
Definition at line 569 of file FeatureNomenclatureTool.cpp.
References Isis::FeatureNomenclature::Approved, Isis::FeatureNomenclature::Feature::cleanName(), Isis::FeatureNomenclature::Feature::controlNet(), Isis::CubeViewport::cube(), Isis::FeatureNomenclatureTool::ViewportFeatureDisplay::features(), Isis::Cube::fileName(), m_extentType, m_findNomenclatureCheckBox, m_foundFeaturesCombo, m_foundNomenclature, m_nomenclatureSearchers, m_showApprovedOnly, Isis::FeatureNomenclature::Feature::status(), Isis::FeatureNomenclature::Feature::target(), and viewportFeatureDisplay().
Referenced by featuresIdentified(), and rebuildFeaturesCombo().
|
privateslot |
A feature nomenclature has finished querying...
we need to translate the features into visible names.
Definition at line 463 of file FeatureNomenclatureTool.cpp.
References Isis::Tool::cubeViewportList(), featuresForViewportFound(), m_nomenclatureEnabled, m_nomenclatureSearchers, and viewportDone().
Referenced by findMissingNomenclature().
|
private |
Update this tool's nomenclature data based on this tool's enabled state and the current viewport list.
This will always remove results of viewports that no longer exist. If displaying nomenclature is enabled, then this will also look for features on any viewports that don't have results and aren't currently querying.
Definition at line 695 of file FeatureNomenclatureTool.cpp.
References Isis::Tool::cubeViewportList(), m_nomenclatureEnabled, m_nomenclatureSearchers, rebuildFeaturesCombo(), removeFeatureDisplay(), viewportFeaturesFound(), and viewportsWithFoundNomenclature().
Referenced by findNomenclatureStateChanged(), and updateTool().
|
private |
Query for nomenclature on the given viewport.
vp | A viewport that both has no results and is not currently querying the nomenclature database. |
Definition at line 734 of file FeatureNomenclatureTool.cpp.
References Isis::CubeViewport::camera(), Isis::CubeViewport::cube(), featuresIdentified(), Isis::UniversalGroundMap::GroundRange(), Isis::PvlContainer::hasKeyword(), Isis::Target::name(), Isis::CubeViewport::projection(), Isis::Spice::target(), toolStateChanged(), Isis::CubeViewport::universalGroundMap(), and viewportDone().
|
privateslot |
The 'Name Features' check box has changed state.
Handle identifying any missing features and naming any already-found features if enabling, hide all names if disabling.
Definition at line 487 of file FeatureNomenclatureTool.cpp.
References Isis::Tool::cubeViewportList(), findMissingNomenclature(), m_nomenclatureEnabled, and toolStateChanged().
Referenced by createToolBarWidget().
QColor Isis::FeatureNomenclatureTool::fontColor | ( | ) | const |
What is the font color to use?
Definition at line 161 of file FeatureNomenclatureTool.cpp.
References m_fontColor.
Referenced by Isis::NomenclatureToolConfigDialog::readSettings().
int Isis::FeatureNomenclatureTool::fontSize | ( | ) | const |
Retrieve the font size of the features in this tool.
Definition at line 171 of file FeatureNomenclatureTool.cpp.
References m_fontSize.
Referenced by Isis::FeatureNomenclatureTool::ViewportFeatureDisplay::handleViewChanged(), and Isis::NomenclatureToolConfigDialog::readSettings().
|
virtual |
This is the name of the menu that should be passed into "addTo()".
Reimplemented from Isis::Tool.
Definition at line 291 of file FeatureNomenclatureTool.cpp.
|
protectedvirtualinherited |
p | |
s |
Definition at line 367 of file Tool.cpp.
Referenced by Isis::Tool::addViewportConnections(), and Isis::Tool::removeViewportConnections().
|
protectedvirtual |
This handles a mouse release on one of the cube viewports when this tool is active.
The responsibilities are forwarde to ViewportFeatureDisplay::handleMouseClicked().
p | The point in the viewport where the mouse was released |
s | The mouse buttons that were released |
Reimplemented from Isis::Tool.
Definition at line 391 of file FeatureNomenclatureTool.cpp.
References Isis::Tool::cubeViewport(), Isis::FeatureNomenclatureTool::ViewportFeatureDisplay::handleMouseClicked(), m_nomenclatureEnabled, and viewportFeatureDisplay().
|
protectedvirtualinherited |
p |
Definition at line 358 of file Tool.cpp.
Referenced by Isis::Tool::addViewportConnections(), and Isis::Tool::removeViewportConnections().
|
protectedvirtualslotinherited |
p |
Definition at line 352 of file Tool.cpp.
Referenced by Isis::Tool::addViewportConnections(), and Isis::Tool::removeViewportConnections().
|
privateslot |
Update the screen coordinates of the named features because the viewport has changed it's mappings.
This uses the already found cube sample, line positions... it just needs to do the appropriate transformations from cube to viewport. This method does not cause a repaint.
Definition at line 510 of file FeatureNomenclatureTool.cpp.
References m_foundNomenclature, and m_nomenclatureEnabled.
Referenced by setFontSize(), setShowApprovedOnly(), setVectorType(), and viewportDone().
|
privateslot |
When this tool is activated (clicked on in the tool bar), turn ourselves on immediately.
Definition at line 524 of file FeatureNomenclatureTool.cpp.
References m_findNomenclatureCheckBox.
Referenced by FeatureNomenclatureTool().
|
virtual |
Paint features on the given viewport.
vp | The viewport that needs painted |
painter | The painter to use for painting |
Reimplemented from Isis::Tool.
Definition at line 132 of file FeatureNomenclatureTool.cpp.
References m_extentType, m_fontColor, m_fontSize, m_nomenclatureEnabled, m_showApprovedOnly, None, Isis::FeatureNomenclatureTool::ViewportFeatureDisplay::paint(), viewportFeatureDisplay(), and viewportFeaturesFound().
|
private |
Read this tool's preserved state.
This uses the current state as defaults, so please make sure your variables are initialized before calling this method.
Definition at line 990 of file FeatureNomenclatureTool.cpp.
References Isis::FileName::expanded(), m_defaultEnabled, m_disclaimedAlready, m_extentType, m_fontColor, m_fontSize, and m_showApprovedOnly.
Referenced by FeatureNomenclatureTool().
|
private |
Rebuild m_foundFeaturesCombo's data from scratch.
This should only be necessary when viewports are lost.
Definition at line 783 of file FeatureNomenclatureTool.cpp.
References featuresForViewportFound(), m_foundFeaturesCombo, and viewportsWithFoundNomenclature().
Referenced by findMissingNomenclature(), and setShowApprovedOnly().
|
protectedinherited |
Registers the tool to the viewport.
viewport |
Definition at line 327 of file Tool.cpp.
References Isis::Tool::m_cvp, and Isis::MdiCubeViewport::registerTool().
Referenced by Isis::Tool::addTo().
|
inlineprotectedvirtualinherited |
Anytime a tool is created, you must be able to remove it's connections.
cvp |
Reimplemented in Isis::MeasureTool, Isis::TrackTool, and Isis::WindowTool.
Definition at line 261 of file Tool.h.
Referenced by Isis::Tool::removeViewportConnections().
|
private |
Remove knowledge of features on the given viewport.
The viewport does not have to be a valid (allocated) pointer.
vp | The viewport to forget. |
Definition at line 801 of file FeatureNomenclatureTool.cpp.
References m_foundNomenclature.
Referenced by findMissingNomenclature().
|
inlineprotectedvirtualslotinherited |
This is called when actions change which pixels from the cube are displayed.
Definition at line 162 of file Tool.h.
Referenced by Isis::Tool::addViewportConnections(), Isis::Tool::removeViewportConnections(), and viewportDone().
|
slotinherited |
Sets the current viewport to the given cvp.
cvp |
Definition at line 160 of file Tool.cpp.
References Isis::Tool::addViewportConnections(), Isis::Tool::enableToolBar(), Isis::Tool::m_active, Isis::Tool::m_cvp, Isis::Tool::removeViewportConnections(), and Isis::Tool::updateTool().
Referenced by Isis::Tool::addTo(), and Isis::FileTool::closeAll().
void Isis::FeatureNomenclatureTool::setDefaultEnabled | ( | bool | defaultEnabled | ) |
Set whether this tool is enabled by default.
defaultEnabled | True to enable by default |
Definition at line 201 of file FeatureNomenclatureTool.cpp.
References defaultEnabled(), m_defaultEnabled, and writeSettings().
Referenced by Isis::NomenclatureToolConfigDialog::applySettings().
void Isis::FeatureNomenclatureTool::setFontColor | ( | QColor | color | ) |
Set the color to use for drawing on the viewport.
This takes effect immediately.
color | The color to use for drawing |
Definition at line 215 of file FeatureNomenclatureTool.cpp.
References Isis::Tool::cubeViewportList(), m_fontColor, and writeSettings().
Referenced by Isis::NomenclatureToolConfigDialog::applySettings().
void Isis::FeatureNomenclatureTool::setFontSize | ( | int | newFontSize | ) |
Set the font point size to use for drawing text on the viewport.
This takes effect immediately.
newFontSize | The font point size to use for rendering text |
Definition at line 232 of file FeatureNomenclatureTool.cpp.
References Isis::Tool::cubeViewportList(), m_fontSize, nomenclaturePositionsOutdated(), and writeSettings().
Referenced by Isis::NomenclatureToolConfigDialog::applySettings().
void Isis::FeatureNomenclatureTool::setShowApprovedOnly | ( | bool | approvedOnly | ) |
Set whether to show approved features and exclude unapproved features.
approvedOnly | True to show only appproved features |
Definition at line 250 of file FeatureNomenclatureTool.cpp.
References Isis::Tool::cubeViewportList(), m_showApprovedOnly, nomenclaturePositionsOutdated(), rebuildFeaturesCombo(), and writeSettings().
Referenced by Isis::NomenclatureToolConfigDialog::applySettings().
void Isis::FeatureNomenclatureTool::setVectorType | ( | VectorType | show | ) |
Set whether to draw vectors from the feature center to the feature extents on the viewport.
This takes effect immediately.
show | True to show the vectors |
Definition at line 269 of file FeatureNomenclatureTool.cpp.
References Isis::Tool::cubeViewportList(), m_extentType, m_foundNomenclature, nomenclaturePositionsOutdated(), and writeSettings().
Referenced by Isis::NomenclatureToolConfigDialog::applySettings().
bool Isis::FeatureNomenclatureTool::showApprovedOnly | ( | ) | const |
Show approved features only?
Definition at line 181 of file FeatureNomenclatureTool.cpp.
References m_showApprovedOnly.
Referenced by Isis::NomenclatureToolConfigDialog::readSettings().
|
privateslot |
Show the user our nomenclature disclaimer and make note that we have shown the disclaimer.
Definition at line 534 of file FeatureNomenclatureTool.cpp.
References m_disclaimedAlready, m_disclaimerText, and writeSettings().
Referenced by createToolBarWidget(), and toolStateChanged().
|
private |
Show a dialog with full feature details of a given feature.
feature | The feature to describe |
Definition at line 814 of file FeatureNomenclatureTool.cpp.
References Isis::FeatureNomenclature::Feature::toWidget().
Referenced by Isis::FeatureNomenclatureTool::ViewportFeatureDisplay::handleMouseClicked().
|
private |
Show a web view pointed to the feature's web page.
feature | The feature to bring up in the web view |
Definition at line 847 of file FeatureNomenclatureTool.cpp.
References Isis::FeatureNomenclature::Feature::referenceUrl().
Referenced by Isis::FeatureNomenclatureTool::ViewportFeatureDisplay::handleMouseClicked().
|
inlineinherited |
returns the path to the icon directory.
Definition at line 127 of file Tool.h.
References Isis::Tool::m_toolIconDir.
Referenced by Isis::AdvancedTrackTool::AdvancedTrackTool(), Isis::BlinkTool::BlinkTool(), Isis::MatchTool::createActions(), Isis::QnetTool::createActions(), Isis::StereoTool::createMenus(), Isis::PanTool::createToolBarWidget(), Isis::BandTool::createToolBarWidget(), Isis::StereoTool::createToolBarWidget(), Isis::ZoomTool::createToolBarWidget(), Isis::EditTool::createToolBarWidget(), Isis::FindTool::createToolBarWidget(), Isis::StretchTool::createToolBarWidget(), Isis::FileTool::FileTool(), Isis::FindTool::FindTool(), Isis::HistogramTool::HistogramTool(), Isis::SpecialPixelTool::SpecialPixelTool(), Isis::RubberBandComboBox::toolIconDir(), Isis::PanTool::toolPadAction(), Isis::ScatterPlotTool::toolPadAction(), Isis::HistogramTool::toolPadAction(), Isis::BandTool::toolPadAction(), Isis::SunShadowTool::toolPadAction(), Isis::SpectralPlotTool::toolPadAction(), Isis::SpatialPlotTool::toolPadAction(), Isis::MeasureTool::toolPadAction(), Isis::StereoTool::toolPadAction(), Isis::ControlNetTool::toolPadAction(), Isis::ZoomTool::toolPadAction(), Isis::EditTool::toolPadAction(), toolPadAction(), Isis::StatisticsTool::toolPadAction(), Isis::FindTool::toolPadAction(), Isis::StretchTool::toolPadAction(), Isis::MatchTool::toolPadAction(), Isis::QnetTool::toolPadAction(), Isis::WindowTool::WindowTool(), and Isis::ZoomTool::ZoomTool().
Add this tool's action to the toolpad.
This defines the name and hotkey of this tool.
toolpad |
Reimplemented from Isis::Tool.
Definition at line 364 of file FeatureNomenclatureTool.cpp.
References Isis::Tool::toolIconDir().
|
private |
This should be called any time this tool's enabled or searching state could have changed.
This enabled/disables and shows/hides widgets appropriately to match the current state.
Definition at line 858 of file FeatureNomenclatureTool.cpp.
References featureSelected(), m_action, m_disclaimedAlready, m_findNomenclatureCheckBox, m_nomenclatureCenterBtn, m_nomenclatureEnabled, m_nomenclatureSearchers, m_queryingProgress, and showDisclaimer().
Referenced by findMissingNomenclature(), findNomenclatureStateChanged(), and viewportDone().
|
protectedvirtual |
Updates the state of the current tool.
This will find any missing nomenclature if appropriate.
Reimplemented from Isis::Tool.
Definition at line 404 of file FeatureNomenclatureTool.cpp.
References findMissingNomenclature().
FeatureNomenclatureTool::VectorType Isis::FeatureNomenclatureTool::vectorType | ( | ) | const |
Draw vectors to the extents of features?
Definition at line 191 of file FeatureNomenclatureTool.cpp.
References m_extentType.
Referenced by Isis::FeatureNomenclatureTool::FeaturePosition::applyExtentType(), Isis::FeatureNomenclatureTool::ViewportFeatureDisplay::applyExtentType(), Isis::FeatureNomenclatureTool::FeaturePosition::FeaturePosition(), Isis::FeatureNomenclatureTool::ViewportFeatureDisplay::handleViewChanged(), Isis::FeatureNomenclatureTool::ViewportFeatureDisplay::paint(), Isis::NomenclatureToolConfigDialog::readSettings(), and Isis::FeatureNomenclatureTool::ViewportFeatureDisplay::ViewportFeatureDisplay().
|
private |
Finalize the search results for the given viewport.
The viewport doesn't have to be a valid (allocated) pointer. This will destroy any searchers with the given viewport, and if there are no found results for the viewport this will create a blank one as a place holder. This prevents searching for features on the viewport again.
vp | The viewport to finalize the search results for |
Definition at line 892 of file FeatureNomenclatureTool.cpp.
References m_extentType, m_foundNomenclature, m_nomenclatureSearchers, nomenclaturePositionsOutdated(), Isis::Tool::screenPixelsChanged(), toolStateChanged(), and viewportFeatureDisplay().
Referenced by featuresIdentified(), and findMissingNomenclature().
|
private |
Map from viewport to feature display.
vp | The viewport to map |
Definition at line 923 of file FeatureNomenclatureTool.cpp.
References m_foundNomenclature.
Referenced by centerOnFeature(), featuresForViewportFound(), mouseButtonRelease(), paintViewport(), viewportDone(), and viewportFeaturesFound().
|
private |
Map from viewport to feature display.
vp | The viewport to map |
Definition at line 941 of file FeatureNomenclatureTool.cpp.
References m_foundNomenclature.
|
private |
Test if features have already been found for a given viewport.
vp | The viewport to test |
Definition at line 960 of file FeatureNomenclatureTool.cpp.
References viewportFeatureDisplay().
Referenced by findMissingNomenclature(), and paintViewport().
|
private |
Get a list of viewports with found nomenclature.
This may include viewports that no longer exist but haven't been cleaned up already.
Definition at line 973 of file FeatureNomenclatureTool.cpp.
References m_foundNomenclature.
Referenced by centerOnFeature(), findMissingNomenclature(), and rebuildFeaturesCombo().
|
private |
Write out this tool's preserved state between runs.
This is NOT called on close, so you should call this any time you change the preserved state.
Definition at line 1012 of file FeatureNomenclatureTool.cpp.
References Isis::FileName::expanded(), m_defaultEnabled, m_disclaimedAlready, m_extentType, m_fontColor, m_fontSize, and m_showApprovedOnly.
Referenced by setDefaultEnabled(), setFontColor(), setFontSize(), setShowApprovedOnly(), setVectorType(), and showDisclaimer().
|
private |
This is the 'Show Nomenclature' toggleable action in the options menu.
Definition at line 324 of file FeatureNomenclatureTool.h.
Referenced by addTo(), and toolStateChanged().
|
private |
Do we turn ourselves on immediately?
Definition at line 374 of file FeatureNomenclatureTool.h.
Referenced by defaultEnabled(), FeatureNomenclatureTool(), readSettings(), setDefaultEnabled(), and writeSettings().
|
private |
Have we ever shown the user our disclaimer?
Definition at line 376 of file FeatureNomenclatureTool.h.
Referenced by FeatureNomenclatureTool(), readSettings(), showDisclaimer(), toolStateChanged(), and writeSettings().
|
private |
This is the 'Disclaimer' button in this tool's tool bar.
Definition at line 343 of file FeatureNomenclatureTool.h.
Referenced by createToolBarWidget(), and FeatureNomenclatureTool().
|
private |
The (HTML) contents of the disclaimer to show the user.
Definition at line 367 of file FeatureNomenclatureTool.h.
Referenced by FeatureNomenclatureTool(), and showDisclaimer().
|
private |
How we need to draw extents (if at all)
Definition at line 378 of file FeatureNomenclatureTool.h.
Referenced by FeatureNomenclatureTool(), featuresForViewportFound(), paintViewport(), readSettings(), setVectorType(), vectorType(), viewportDone(), and writeSettings().
|
private |
This is the 'Name Features' check box when this tool is active.
Definition at line 327 of file FeatureNomenclatureTool.h.
Referenced by addTo(), createToolBarWidget(), FeatureNomenclatureTool(), featuresForViewportFound(), onToolActivated(), and toolStateChanged().
|
private |
The color to use when drawing on the viewport.
Definition at line 372 of file FeatureNomenclatureTool.h.
Referenced by FeatureNomenclatureTool(), fontColor(), paintViewport(), readSettings(), setFontColor(), and writeSettings().
|
private |
The font size to use when naming features.
Definition at line 370 of file FeatureNomenclatureTool.h.
Referenced by FeatureNomenclatureTool(), fontSize(), paintViewport(), readSettings(), setFontSize(), and writeSettings().
|
private |
This combo box lists all of the found features and their viewports.
The data stored in this combo box is of format:
Map<QString, QVariant>: "Viewport" -> MdiCubeViewport* "Feature" -> FeatureNomenclature::Feature "Target" -> QString(target name, all upper case)
Definition at line 337 of file FeatureNomenclatureTool.h.
Referenced by centerOnSelectedFeature(), createToolBarWidget(), FeatureNomenclatureTool(), featureSelected(), featuresForViewportFound(), and rebuildFeaturesCombo().
|
private |
The nomenclature that has been identified, one for each viewport.
Definition at line 351 of file FeatureNomenclatureTool.h.
Referenced by FeatureNomenclatureTool(), featuresForViewportFound(), nomenclaturePositionsOutdated(), removeFeatureDisplay(), setVectorType(), viewportDone(), viewportFeatureDisplay(), viewportsWithFoundNomenclature(), and ~FeatureNomenclatureTool().
|
private |
This is the 'Center' button in this tool's tool bar.
Definition at line 339 of file FeatureNomenclatureTool.h.
Referenced by createToolBarWidget(), FeatureNomenclatureTool(), featureSelected(), and toolStateChanged().
|
private |
Do we find and display nomenclature? This corresponds to the 'Name Features' check box and the 'Show Nomenclature' action in the options menu.
Definition at line 364 of file FeatureNomenclatureTool.h.
Referenced by addTo(), createToolBarWidget(), FeatureNomenclatureTool(), featureSelected(), featuresIdentified(), findMissingNomenclature(), findNomenclatureStateChanged(), mouseButtonRelease(), nomenclaturePositionsOutdated(), paintViewport(), and toolStateChanged().
|
private |
This is the 'Tool Options' button in this tool's tool bar.
Definition at line 341 of file FeatureNomenclatureTool.h.
Referenced by createToolBarWidget(), and FeatureNomenclatureTool().
|
private |
The nomenclature being queried currently, one for each viewport that has no found nomenclature.
Definition at line 357 of file FeatureNomenclatureTool.h.
Referenced by FeatureNomenclatureTool(), featuresForViewportFound(), featuresIdentified(), findMissingNomenclature(), toolStateChanged(), viewportDone(), and ~FeatureNomenclatureTool().
|
private |
This is a busy indicator that is visible when queries are out to the nomenclature database.
Definition at line 348 of file FeatureNomenclatureTool.h.
Referenced by createToolBarWidget(), FeatureNomenclatureTool(), and toolStateChanged().
|
private |
Only show IAU approved features.
Definition at line 380 of file FeatureNomenclatureTool.h.
Referenced by FeatureNomenclatureTool(), featuresForViewportFound(), Isis::FeatureNomenclatureTool::ViewportFeatureDisplay::handleViewChanged(), paintViewport(), readSettings(), setShowApprovedOnly(), showApprovedOnly(), and writeSettings().