Loading [MathJax]/jax/output/NativeMML/config.js
Isis Developer Reference
AbstractPlotTool.h
Go to the documentation of this file.
1#ifndef AbstractPlotTool_h
2#define AbstractPlotTool_h
3
10/* SPDX-License-Identifier: CC0-1.0 */
11
12// this should be the only include in this file!
13#include "Tool.h"
14
15// We need PlotCurve::Units
16#include "PlotCurve.h"
17
18#include <QPointer>
19
20class QComboBox;
21class QPen;
22
23namespace Isis {
24 class CubePlotCurve;
25 class PlotWindow;
26 class RubberBandComboBox;
27
43 class AbstractPlotTool : public Tool {
44 Q_OBJECT
45
46 public:
48 virtual ~AbstractPlotTool();
49
50 virtual void paintViewport(MdiCubeViewport *vp, QPainter *painter);
51
52 public slots:
53 void removeWindow(QObject *);
55 void showPlotWindow();
56
57 protected slots:
58 void repaintViewports();
59
60 protected:
62 static CubePlotCurve *createCurve(QString name, QPen pen,
63 PlotCurve::Units xUnits, PlotCurve::Units yUnits);
64 QWidget *createToolBarWidget(QStackedWidget *parent);
65
74 virtual PlotWindow *createWindow() = 0;
75 virtual void updateTool();
78
85 virtual void detachCurves() = 0;
86 PlotWindow *selectedWindow(bool createIfNeeded = true);
87
88 private slots:
89 void selectedWindowChanged();
90
91 private:
98 QPointer<QComboBox> m_selectWindowCombo;
99 };
100}
101
102#endif
Parent class for plotting tools which provides common functionality.
Definition: AbstractPlotTool.h:43
void repaintViewports()
This method causes all of the viewports to be repainted.
Definition: AbstractPlotTool.cpp:362
void removeWindow(QObject *)
When a user closes a window, we want to remove that window from our combo box for selecting the activ...
Definition: AbstractPlotTool.cpp:203
PlotWindow * selectedWindow(bool createIfNeeded=true)
Get the 'active' plot window (the window selected by the user to contain new curves).
Definition: AbstractPlotTool.cpp:256
virtual void paintViewport(MdiCubeViewport *vp, QPainter *painter)
This method allows each plot window to paint any information it wants onto the cube viewports.
Definition: AbstractPlotTool.cpp:81
QWidget * createToolBarWidget(QStackedWidget *parent)
This provides the standard plot tool options, such as selecting an active plot window.
Definition: AbstractPlotTool.cpp:103
QList< MdiCubeViewport * > viewportsToPlot()
Get a list of linked viewports that should be plotting when a new plot is requested.
Definition: AbstractPlotTool.cpp:133
QList< PlotWindow * > plotWindows()
Get a list of all of the instantiated plot windows.
Definition: AbstractPlotTool.cpp:155
virtual ~AbstractPlotTool()
Clean up the abstract plot tool.
Definition: AbstractPlotTool.cpp:54
void showPlotWindow()
displays the plot window
Definition: AbstractPlotTool.cpp:350
virtual void detachCurves()=0
This will be called when the selected plot window changes.
virtual void updateTool()
This forwards all update calls to the plot windows.
Definition: AbstractPlotTool.cpp:118
PlotWindow * addWindow()
This creates and initializes everything about a plot window.
Definition: AbstractPlotTool.cpp:303
static CubePlotCurve * createCurve(QString name, QPen pen, PlotCurve::Units xUnits, PlotCurve::Units yUnits)
This is a helper method for children.
Definition: AbstractPlotTool.cpp:233
AbstractPlotTool(QWidget *parent)
When you construct a plot tool, this initializes the common functionality between plot tools.
Definition: AbstractPlotTool.cpp:34
virtual PlotWindow * createWindow()=0
This needs to be implemented by children to instantiate a plot window of the appropriate child class ...
This is a plot curve with information relating it to a particular cube or region of a cube.
Definition: CubePlotCurve.h:53
Cube display widget for certain Isis MDI applications.
Definition: MdiCubeViewport.h:39
Units
These are all the possible units for the x or y data in a plot curve.
Definition: PlotCurve.h:54
Definition: PlotWindow.h:88
Base class for the Qisis tools.
Definition: Tool.h:67
This is free and unencumbered software released into the public domain.
Definition: BoxcarCachingAlgorithm.h:13
This is free and unencumbered software released into the public domain.
Definition: Apollo.h:16

U.S. Department of the Interior | U.S. Geological Survey
ISIS | Privacy & Disclaimers | Astrogeology Research Program
To contact us, please post comments and questions on the USGS Astrogeology Discussion Board
To report a bug, or suggest a feature go to: ISIS Github
File Modified: 02/21/2025 21:56:14