Diana Software
Public Member Functions | Private Attributes | Static Private Attributes | List of all members
QGScatterPlot Class Reference

Class for GUI scatter plots. More...

Inheritance diagram for QGScatterPlot:
QGGraph QGPlot

Public Member Functions

 QGScatterPlot ()
 Default constructor. More...
 
 QGScatterPlot (const QGScatterPlot &)
 Copy constructor. More...
 
virtual ~QGScatterPlot ()
 Destructor. More...
 
void AutoSetStyle ()
 Automatically set the scatter plot style. More...
 
void Display ()
 Display scatter plot. More...
 
void DisplayEditWindow ()
 Display edit window. More...
 
void DrawStyleScatterPlot ()
 Draw a mini-scatter plot showing the style of the scatter plot. More...
 
void Duplicate ()
 Duplicate the scatter plot. More...
 
void Erase ()
 Erase the scatter plot. More...
 
void Generate (QChain *chain=0)
 Generate the scatter plot. More...
 
void GetParametersFromEditWindow ()
 Get parameters from edit window. More...
 
TGraph * GetStyleScatterPlot ()
 Get style scatter plot. More...
 
void MakeStylePlot ()
 Make style plot. More...
 
void SetName (const char *name=0)
 Set name of the scatter plot. More...
 
void SetProperty (const std::string &key, const std::string &value)
 Set property (used for opening a session) More...
 
- Public Member Functions inherited from QGGraph
 QGGraph ()
 Default constructor. More...
 
 QGGraph (const QGGraph &)
 Copy constructor. More...
 
virtual ~QGGraph ()
 Destructor. More...
 
virtual const char * GetName () const
 Get graph name. More...
 
virtual void Reset ()
 Reset the graph to an empty state. More...
 
virtual void SetPoints (Int_t n, const Double_t *x, const Double_t *y)
 Set the points of the graph. More...
 
- Public Member Functions inherited from QGPlot
 QGPlot ()
 Default constructor. More...
 
 QGPlot (const QGPlot &)
 Copy constructor. More...
 
virtual ~QGPlot ()
 Destructor. More...
 
virtual void AddCut (const std::string &cut)
 Add cut. More...
 
virtual std::string GeneratePlotName (const std::string &baseName) const
 Generate a name for the plot. More...
 
virtual TCanvas * GetCanvas ()
 Get pointer to the associated canvas. More...
 
virtual QGCanvasWindowGetCanvasWindow () const
 Get pointer to the canvas window to which the plot is associated. More...
 
virtual void GetCanvasWindowFromEditWindow ()
 Get canvas window from edit window. More...
 
virtual const std::vector< std::string > & GetCuts () const
 Get cuts applied to make the plot. More...
 
virtual void GetCutsFromEditWindow ()
 Get cuts from edit window. More...
 
virtual QGPlotEditWindowGetEditWindow ()
 Get pointer to edit window. More...
 
virtual const std::string & GetXUnits () const
 Get x-axis units. More...
 
virtual const std::string & GetXVariable () const
 Get x-axis variable. More...
 
virtual const std::string & GetYUnits () const
 Get y-axis units. More...
 
virtual const std::string & GetYVariable () const
 Get y-axis variable. More...
 
virtual bool IsNameInUse (const std::string &name) const
 Check whether string is the name of any plot. More...
 
virtual bool IsSuperimposeSet () const
 Return true if plot is set to be superimposed. More...
 
virtual void MakeCutsString ()
 Make cuts string. More...
 
virtual bool NeedsRegeneration () const
 Check whether plot needs to be regenerated. More...
 
virtual void Plot ()
 Plot this in the associated canvas window, generating it if necessary. More...
 
virtual void SetCanvasWindow (QGCanvasWindow *window)
 Set the canvas window to which the plot is associated. More...
 
virtual void SetCuts (const std::vector< std::string > &cuts)
 Set cuts to apply in generating the plot. More...
 
virtual void SetPlotEditWindow (QGPlotEditWindow *window)
 Set plot edit window. More...
 
virtual void SetRegenerate (bool flag=true)
 Set whether the plot needs to be regenerated. More...
 
virtual void SetSuperimpose (bool flag=false)
 Set whether the plot should be superimposed. More...
 
virtual void SetXVariable (const std::string &x)
 Set X-axis variable. More...
 
virtual void SetXUnits (const std::string &units)
 Set X-axis units. More...
 
virtual void SetYVariable (const std::string &y)
 Set Y-axis variable. More...
 
virtual void SetYUnits (const std::string &units)
 Set Y-axis units. More...
 

Private Attributes

TGraph * fStyleScatterPlot
 Mini-scatter plot to show style of this scatter plot. More...
 

Static Private Attributes

static std::list< QGScatterPlot * > fScatterPlots
 Collection of pointers to all QGScatterPlots. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from QGPlot
static QGPlotGetPlotByName (const std::string &name)
 Get plot by name. More...
 
static const std::list< QGPlot * > & GetPlots ()
 Get collection of plots. More...
 
static void ShowPlotsList ()
 Show plots list. More...
 
- Protected Attributes inherited from QGPlot
QGCanvasWindowfCanvasWindow
 Canvas window to which plot is associated. More...
 
std::vector< std::string > fCuts
 Cuts applied to make the plot. More...
 
std::string fCutsString
 Cuts in a single string. More...
 
bool fNeedsRegeneration
 Indicates whether plot needs to be regenerated because settings have changed. More...
 
QGPlotEditWindowfPlotEditWindow
 Pointer to plot edit window. More...
 
bool fSuperimpose
 Indicates whether plot should be superimposed on existing plot. More...
 
std::string fXVariable
 X-axis variable. More...
 
std::string fXUnits
 X-axis units. More...
 
std::string fYVariable
 Y-axis variable. More...
 
std::string fYUnits
 Y-axis units. More...
 
- Static Protected Attributes inherited from QGPlot
static std::list< QGPlot * > fPlots
 Collection of pointers to all QGPlots. More...
 

Detailed Description

Class for GUI scatter plots.

Author
Adam Bryant (adam_.nosp@m.brya.nosp@m.nt@be.nosp@m.rkel.nosp@m.ey.ed.nosp@m.u)

Definition at line 15 of file QGScatterPlot.hh.

Constructor & Destructor Documentation

◆ QGScatterPlot() [1/2]

QGScatterPlot::QGScatterPlot ( )

Default constructor.

Definition at line 39 of file QGScatterPlot.cc.

References fScatterPlots, MakeStylePlot(), and SetName().

Referenced by Duplicate().

◆ QGScatterPlot() [2/2]

QGScatterPlot::QGScatterPlot ( const QGScatterPlot scatterPlot)

Copy constructor.

Definition at line 49 of file QGScatterPlot.cc.

References fScatterPlots, MakeStylePlot(), and SetName().

◆ ~QGScatterPlot()

QGScatterPlot::~QGScatterPlot ( )
virtual

Destructor.

Definition at line 59 of file QGScatterPlot.cc.

References QGPlot::fPlotEditWindow, fScatterPlots, and fStyleScatterPlot.

Member Function Documentation

◆ AutoSetStyle()

void QGScatterPlot::AutoSetStyle ( )
virtual

Automatically set the scatter plot style.

Reimplemented from QGPlot.

Definition at line 71 of file QGScatterPlot.cc.

References fScatterPlots, and MakeStylePlot().

Referenced by Duplicate(), and QGPlotIconsFrame::HandleScatterPlotButton().

◆ Display()

void QGScatterPlot::Display ( )
virtual

◆ DisplayEditWindow()

void QGScatterPlot::DisplayEditWindow ( )
virtual

◆ DrawStyleScatterPlot()

void QGScatterPlot::DrawStyleScatterPlot ( )

Draw a mini-scatter plot showing the style of the scatter plot.

Definition at line 180 of file QGScatterPlot.cc.

References fStyleScatterPlot, and MakeStylePlot().

Referenced by DisplayEditWindow().

◆ Duplicate()

void QGScatterPlot::Duplicate ( )
virtual

Duplicate the scatter plot.

Reimplemented from QGPlot.

Definition at line 195 of file QGScatterPlot.cc.

References AutoSetStyle(), DisplayEditWindow(), and QGScatterPlot().

◆ Erase()

void QGScatterPlot::Erase ( )
virtual

Erase the scatter plot.

Reimplemented from QGPlot.

Definition at line 202 of file QGScatterPlot.cc.

References QGPlot::fCanvasWindow, QGPlotFrame::GetEmbeddedCanvas(), QGCanvasWindow::GetPlotFrame(), and QGCanvasWindow::RemoveFromDrawnPlots().

◆ Generate()

void QGScatterPlot::Generate ( QChain chain = 0)
virtual

◆ GetParametersFromEditWindow()

void QGScatterPlot::GetParametersFromEditWindow ( )
virtual

Get parameters from edit window.

Reimplemented from QGPlot.

Definition at line 242 of file QGScatterPlot.cc.

References QGPlot::fPlotEditWindow, QGPlot::SetSuperimpose(), QGPlot::SetXUnits(), QGPlot::SetXVariable(), QGPlot::SetYUnits(), and QGPlot::SetYVariable().

◆ GetStyleScatterPlot()

TGraph* QGScatterPlot::GetStyleScatterPlot ( )
inline

Get style scatter plot.

Definition at line 51 of file QGScatterPlot.hh.

References fStyleScatterPlot.

◆ MakeStylePlot()

void QGScatterPlot::MakeStylePlot ( )

Make style plot.

Definition at line 257 of file QGScatterPlot.cc.

References fStyleScatterPlot.

Referenced by AutoSetStyle(), DrawStyleScatterPlot(), and QGScatterPlot().

◆ SetName()

void QGScatterPlot::SetName ( const char *  name = 0)
virtual

Set name of the scatter plot.

Reimplemented from QGPlot.

Definition at line 270 of file QGScatterPlot.cc.

References QGPlot::GeneratePlotName(), and QGPlot::IsNameInUse().

Referenced by QGScatterPlot().

◆ SetProperty()

void QGScatterPlot::SetProperty ( const std::string &  key,
const std::string &  value 
)
virtual

Set property (used for opening a session)

Reimplemented from QGPlot.

Definition at line 287 of file QGScatterPlot.cc.

References MARKER_COLOR_KEY, MARKER_SIZE_KEY, MARKER_STYLE_KEY, and QGPlot::SetProperty().

Member Data Documentation

◆ fScatterPlots

list< QGScatterPlot * > QGScatterPlot::fScatterPlots
staticprivate

Collection of pointers to all QGScatterPlots.

Definition at line 64 of file QGScatterPlot.hh.

Referenced by AutoSetStyle(), QGScatterPlot(), and ~QGScatterPlot().

◆ fStyleScatterPlot

TGraph* QGScatterPlot::fStyleScatterPlot
private

Mini-scatter plot to show style of this scatter plot.

Definition at line 67 of file QGScatterPlot.hh.

Referenced by Display(), DrawStyleScatterPlot(), GetStyleScatterPlot(), MakeStylePlot(), and ~QGScatterPlot().


The documentation for this class was generated from the following files: