27 #ifndef PLOTMSPLOTMANAGER_H_
28 #define PLOTMSPLOTMANAGER_H_
38 class PlotMSPlotManagerWatcher;
39 class PlotMSPlotParameters;
81 const std::vector<PlotMSPlot*>&
plots()
const;
115 std::vector<casacore::String>
getFiles()
const;
bool findEmptySpot(casacore::Int &row, casacore::Int &col)
bool isOwner(int row, int col, PlotMSPlot *plot)
PlotMSApp * itsParent_
Parent.
void notifyWatchers() const
Notifies any watchers that the managed plots have changed.
void clearCanvas(int row, int col)
unsigned int numPlots() const
Returns the number of plots.
QList< PlotMSPlot * > getCanvasPlots(int row, int col) const
void getGridSize(casacore::Int &rows, casacore::Int &cols)
Return the current size of a multi-plot page grid.
PlotMSPlotManager()
Constructor.
PlotMSParameters getPageParameters()
Returns the parameters that control the page display (grid rows & cols).
Parameters for a PlotMSPlot.
PlotMSPlotManagerWatcher()
Constructor.
Subclass of PlotMSWatchedParameters that hold parameters for the whole plotter.
std::vector< PlotMSPlot * > itsPlots_
Plots.
PlotMSPlot * addOverPlot(const PlotMSPlotParameters *p=NULL)
Creates a new PlotMSPlot, initializes it properly, adds it to the plotter, and returns a pointer to i...
void removeWatcher(PlotMSPlotManagerWatcher *watcher)
Removes the given watcher from this manager.
Controller class for plotms.
~PlotMSPlotManager()
Destructor.
PlotMSPages itsPages_
Plot pages.
virtual void plotsChanged(const PlotMSPlotManager &manager)=0
Will be called whenever the plots in the manager change.
void addPlot(PlotMSPlot *plot, const PlotMSPlotParameters *p)
Helper method for add*Plot methods.
void removePlot(PlotMSPlot *plot)
Remove a plot from the display.
PlotMSApp * parent()
Gets/Sets the parent PlotMS.
Class for a single "plot" concept.
PlotMSPlot * plot(unsigned int index)
PlotterPtr plotter()
Returns the plotter used by the parent.
Interface for any class that wants to be notified when the plots in the manager have changed...
void addWatcher(PlotMSPlotManagerWatcher *watcher)
Adds the given watcher to this manager.
const std::vector< PlotMSPlotParameters * > & plotParameters() const
Returns all or one of the plot parameters.
void setParent(PlotMSApp *parent)
virtual ~PlotMSPlotManagerWatcher()
Destructor.
void clearPlotsAndCanvases(bool clearCanvases=true)
Clears out all plots and canvases.
PlotFactoryPtr itsFactory_
Plot factory.
std::vector< PlotMSPlotManagerWatcher * > itsWatchers_
Watchers.
bool isPlottable(PlotMSPlot *plot)
Returns whether or not a canvas has been allocated for the plot.
void logMessage(const QString &msg) const
Post a plot message to the logger.
const std::vector< PlotMSPlot * > & plots() const
Returns all or one of the plots.
Class which manages PlotMSPlots for plotms.
void waitForDrawing()
Wait for existing draw threads to finish before we proceed so we don't get a seg fault from a draw th...
Represents (potentially) multiple pages for PlotMS, with one being current (visible) at a time...
PlotterPtr itsPlotter_
Plotter.
std::vector< casacore::String > getFiles() const
bool pageGridChanged(int rows, int cols, bool override)
Set the new size of a multi-plot display.
std::vector< PlotMSPlotParameters * > itsPlotParameters_
Plot parameters.