|
Isis 3 Programmer Reference
|
Go to the documentation of this file.
31 #include "MainWindow.h"
38 class QwtPlotSpectrogram;
43 class QListWidgetItem;
48 template <
typename A,
typename B>
struct QPair;
51 class MdiCubeViewport;
55 class TableMainWindow;
224 void requestFillTable();
252 virtual void dropEvent(QDropEvent *event);
255 using QWidget::mousePressEvent;
269 static bool numericStringLessThan(QString left, QString right);
337 bool m_scheduledFillTable;
virtual void dragEnterEvent(QDragEnterEvent *event)
When a user drags data into our plot window, we need to indicate whether or not this data is compatib...
bool m_plotXLogScale
Tracks if the plot X axis is using a log (true) or linear (false) scale.
QLineEdit * m_xMinEdit
Set Scale Dialog's edit for the min X-axis value.
PlotCurve::Units yAxisUnits() const
This is the data-type of the curves' y data in this plot window.
QPointer< QAction > m_showHideAllMarkers
Hide all markers action.
void setMenus(QList< QMenu * > menus, QList< QAction * > actions)
Sets up the menus added from a parent object.
QwtLegend * m_legend
The legend inserted in this plot.
void showWindow()
Shows the plot window, and raises it to the front of any overlapping sibling widgets.
void showHideGrid()
This method hides/shows the grid on the plotWindow and changes the text for the action.
Cube display widget for certain Isis MDI applications.
void createBestFitLine()
This method prompts the user to select the best fit line criterea.
QwtPlotGrid * m_grid
Plot grid lines.
QPointer< QAction > m_showHideGrid
Show plot grid lines action.
@ ResetScaleMenuOption
This option provides the user with an alternative zoom out button.
void setLabels()
Makes the user specified changes to the plot labels.
bool m_autoscaleAxes
True if we are autoscaling the x-bottom and y-left axes.
This is free and unencumbered software released into the public domain.
QString plotTitle() const
Returns the plot title.
PlotWindow(QString title, PlotCurve::Units xAxisUnits, PlotCurve::Units yAxisUnits, QWidget *parent, MenuOptions optionsToProvide=AllMenuOptions)
This constructs a plot window.
This is a plot curve with information relating it to a particular cube or region of a cube.
void setAxisLabel(int axisId, QString title)
Sets the plots given axis title to the given string.
void showHelp()
This method creates and shows the help dialog box for the plot window.
void showHideAllMarkers()
Shows/Hides all the markers(symbols)
void setUserValues()
This method sets the scale for the axis according to the user specified numbers.
bool userCanAddCurves() const
Ask if a user action can add this curve to this window in general.
void fillTable()
Fills in the table with the data from the current curves in the plotWindow immediately.
QCheckBox * m_yLogCheckBox
Set Scale Dialog's checkbox for using logarithmic scale for the y axis.
void showHideAllCurves()
This method shows or hides all of the curves in the plotWindow.
void printPlot()
Provides printing support of the plot image.
@ ShowHideCurvesMenuOption
This option is titled 'Hide All Curves' which makes all curves invisible.
void changePlotLabels()
This method creates the dialog box which allows the user to relabel the plot window.
QLineEdit * m_yMaxEdit
Set Scale Dialog's edit for the max Y-axis value.
QLineEdit * m_plotTitleText
Set Labels Dialog's edit for the plot title.
MenuOptions
There is a menu option for everything in the plot window's menu.
void showTable()
This method is called from the showTable action on the tool bar There are some checks done to make su...
PlotCurve::Units m_yAxisUnits
The units of the data on the y-left axis.
static QString defaultWindowTitle()
This is the typical suffix for plot windows, it's here in case we want to update all plot windows to ...
QPair< double, double > findDataRange(int axisId) const
This calculates the data range of the specified axis (works with xBottom and yLeft only).
void updateVisibility(PlotCurve *curve)
This method sets the visibility states in the curve (and it's symbols) to match with this window's cu...
Units
These are all the possible units for the x or y data in a plot curve.
virtual void update(MdiCubeViewport *activeViewport)
This is provided to allow children to react to tool updates.
virtual void add(CubePlotCurve *pc)
This method adds the curves to the plot.
@ ShowHideGridMenuOption
This option enables the ability for a user to enable a grid over the plot area.
@ BackgroundSwitchMenuOption
This option enables the ability for a user to change the background color of the plot from black to w...
QCheckBox * m_xLogCheckBox
Set Scale Dialog's checkbox for using logarithmic scale for the x axis.
QwtPlotZoomer * m_zoomer
Plot Zoomer.
void configurePlotCurves()
This method creates a CubePlotCurveConfigureDialog object.
@ ShowTableMenuOption
This option brings up the table.
@ AllMenuOptions
This is all of the available menu options.
QwtPlotZoomer * zoomer()
Get this window's plot's zoomer.
PlotCurve::Units xAxisUnits() const
This is the data-type of the curves' x data in this plot window.
void setupDefaultMenu(MenuOptions optionsToProvide)
The user can add menu items from parent classes, but there are some menu items that are common betwee...
void onClipboardChanged()
This slot will be called when the system clipboard is changed.
QColor plotBackgroundColor() const
Returns the plot's background color.
QAction * m_pasteAct
This is the paste action in the edit menu to paste a curve into the plot window.
@ RenameLabelsMenuOption
This option enables the ability for a user to change the x/y axis labels and plot title.
TableMainWindow * m_tableWindow
Table window.
virtual void dropEvent(QDropEvent *event)
This is called when a user drops data into our window.
void setUserCanAddCurves(bool)
Allow or disallow users from manually putting curves into this plot window through either copy-and-pa...
void mousePressEvent(QObject *object, QMouseEvent *e)
This is a helper method for the eventFilter() method.
void setDefaultRange()
Resets the x/y min/max to the defaults.
QList< CubePlotCurve * > plotCurves()
Get a comprehensive list of the plot curves inside of this plot window, excluding plot curves that ar...
bool userCanAddCurve(const QMimeData *curve)
Ask if a user action can add this curve to this window.
void scheduleFillTable()
Fills in the table with the data from the current curves in the plotWindow once all current actions/a...
QPointer< QAction > m_showHideAllCurves
Hide all curves action.
@ SaveMenuOption
This option exports the plot into a standard image format.
a subclass of the qisis mainwindow, tablemainwindow handles all of the table tasks.
QPointer< QAction > m_action
Plot window's action.
@ PrintMenuOption
This option sends the plot to a printer.
QWidget * m_parent
Parent widget.
void setPlotBackground(QColor c)
Sets the plot background color to the given color.
@ LineFitMenuOption
This option allows the user to create a best fit line for any of the scatter plot data or cube plot c...
void disableAxisAutoScale()
This turns off scaling the x/y axes automatically.
QList< QwtPlotSpectrogram * > plotSpectrograms()
Get a comprehensive list of the scatter plots (spectrograms) inside of this plot window.
QwtPlot * plot()
Get the plot encapsulated by this PlotWindow.
QLineEdit * m_xAxisText
Set Labels Dialog's edit for the x-axis label.
QToolBar * m_toolBar
Tool bar on the plot window.
bool canAdd(CubePlotCurve *curveToTest) const
This method tests whethere or not a CubePlotCurve can be successfully added to this window.
QLineEdit * m_yAxisText
Set Labels Dialog's edit for the y-axis label.
void savePlot()
This method allows the user to save the plot as a png, jpg, or tif image file.
QLineEdit * m_xMaxEdit
Set Scale Dialog's edit for the max X-axis value.
void autoScaleCheckboxToggled()
This is a helper method for the set scale configuration dialog.
This is free and unencumbered software released into the public domain.
@ SetDisplayRangeMenuOption
This option allows the user to set the x/y axis display value ranges.
QMenuBar * m_menubar
Plot window's menu bar.
bool m_allowUserToAddCurves
Is the window showing the curve markers?
void trackerEnabled()
Enables the plot mouse tracker.
PlotCurve::Units m_xAxisUnits
The units of the data on the x-bottom axis.
@ ShowHideMarkersMenuOption
This option is titled 'Hide All Symbols' which hides all markers.
@ TrackMenuOption
This option enables mouse tracking on the plot area (displays next to the mouse which x/y point you a...
QLineEdit * m_yMinEdit
Set Scale Dialog's edit for the min Y-axis value.
@ ConfigurePlotMenuOption
This option allows the user to change the curve name, color, style size, and symbol of the curve.
Base class for the Qisis main windows.
QCheckBox * m_autoScaleCheckBox
Set Scale Dialog's checkbox for enabling automatic scaling on x & y.
void createWidgets(MenuOptions optionsToProvide)
This method is called by the constructor to create the plot, legend.
void replot()
Reset the scale of the plot, replot it and emit plot changed.
QwtPlot * m_plot
The plot in this window.
void switchBackground()
This method toggles the plot background color between black and white.
void clearPlot()
This method completely clears the plot of all plot items.
@ ClearPlotMenuOption
This option allows the user to delete all of the data inside the plot.
virtual bool eventFilter(QObject *o, QEvent *e)
This method filters the events of the objects it is connected to.
void setPlotTitle(QString pt)
Sets the plot title to the given string.
void plotChanged()
Emitted every time there is a change to the plot window.
void resetScale()
Sets plot scale back to the defaults.
void closed()
Emitted when there is a close event on this window that will be accepted.
bool m_plotYLogScale
Tracks if the plot Y axis is using a log (true) or linear (false) scale.
void pasteCurve()
When the user pastes a curve try to put it into this plot window.
virtual void clearPlotCurves()
This method also clears the plot of all plot items, but does not call the table delete stuff This met...
This is free and unencumbered software released into the public domain.
Q_DECLARE_OPAQUE_POINTER(QwtPlotSpectrogram *)
We have scatter plot types as QVariant data types, so here it's enabled.
Q_DECLARE_METATYPE(Isis::PlotWindow *)
We have plot windows as QVariant data types, so here it's enabled.
virtual void paint(MdiCubeViewport *vp, QPainter *painter)
Paint plot curve information onto the viewport.
@ DefaultHelpMenuOption
Not implemented.