LArSoft  v06_85_00
Liquid Argon Software toolkit - http://larsoft.org/
evd::DrawingPad Class Reference

Base class for event display drawing pads. More...

#include "DrawingPad.h"

Inheritance diagram for evd::DrawingPad:
evd::CalorPad evd::Display3DPad evd::HeaderPad evd::MCBriefPad evd::Ortho3DPad evd::TQPad evd::TWireProjPad

Public Member Functions

 DrawingPad (const char *nm, const char *ti, double x1, double y1, double y2, double x2)
 
 ~DrawingPad ()
 
TPad * Pad ()
 
HeaderDrawerHeaderDraw ()
 
evd_tool::IExperimentDrawerGeometryDraw ()
 
SimulationDrawerSimulationDraw ()
 
RawDataDrawerRawDataDraw ()
 
RecoBaseDrawerRecoBaseDraw ()
 
AnalysisBaseDrawerAnalysisBaseDraw ()
 
HitSelectorHitSelectorGet ()
 

Protected Types

using IExperimentDrawerPtr = std::unique_ptr< evd_tool::IExperimentDrawer >
 

Protected Attributes

TPad * fPad
 The ROOT graphics pad. More...
 
HeaderDrawerfHeaderDraw
 Drawer for event header info. More...
 
IExperimentDrawerPtr fGeometryDraw
 Drawer for detector geometry. More...
 
SimulationDrawerfSimulationDraw
 Drawer for simulation objects. More...
 
RawDataDrawerfRawDataDraw
 Drawer for raw data. More...
 
RecoBaseDrawerfRecoBaseDraw
 Drawer for recobase objects. More...
 
AnalysisBaseDrawerfAnalysisBaseDraw
 Drawer for analysisbase objects. More...
 

Detailed Description

Base class for event display drawing pads.

Definition at line 29 of file DrawingPad.h.

Member Typedef Documentation

Definition at line 51 of file DrawingPad.h.

Constructor & Destructor Documentation

evd::DrawingPad::DrawingPad ( const char *  nm,
const char *  ti,
double  x1,
double  y1,
double  x2,
double  y2 
)

Create a drawing pad for the event display

Parameters
nm: Name of the TPad
ti: Title of the TPad
x1: Relative x position (0-1) of lower left corner
y1: Relative y position (0-1) of lower left corner
x2: Relative x position (0-1) of upper right corner
y2: Relative y position (0-1) of upper right corner

Definition at line 39 of file DrawingPad.cxx.

References fPad.

43  : fPad(0)
44  , fHeaderDraw(0) //Every pointer checked for a 0 value in the destructor should be set to 0 here. aoliv23@lsu.edu
45  , fSimulationDraw(0)
46  , fRawDataDraw(0)
47  , fRecoBaseDraw(0)
49  {
50  fPad = new TPad(nm,ti,x1,y1,x2,y2);
51  fPad->Draw();
52  fPad->cd();
53  }
Float_t y1[n_points_granero]
Definition: compare.C:5
Float_t x1[n_points_granero]
Definition: compare.C:5
Float_t y2[n_points_geant4]
Definition: compare.C:26
AnalysisBaseDrawer * fAnalysisBaseDraw
Drawer for analysisbase objects.
Definition: DrawingPad.h:60
RecoBaseDrawer * fRecoBaseDraw
Drawer for recobase objects.
Definition: DrawingPad.h:59
RawDataDrawer * fRawDataDraw
Drawer for raw data.
Definition: DrawingPad.h:58
TPad * fPad
The ROOT graphics pad.
Definition: DrawingPad.h:53
Float_t x2[n_points_geant4]
Definition: compare.C:26
HeaderDrawer * fHeaderDraw
Drawer for event header info.
Definition: DrawingPad.h:54
SimulationDrawer * fSimulationDraw
Drawer for simulation objects.
Definition: DrawingPad.h:57
evd::DrawingPad::~DrawingPad ( )

Definition at line 57 of file DrawingPad.cxx.

References fAnalysisBaseDraw, fHeaderDraw, fPad, fRawDataDraw, fRecoBaseDraw, and fSimulationDraw.

58  {
59  if (fHeaderDraw) { delete fHeaderDraw; fHeaderDraw = 0; }
60  if (fSimulationDraw) { delete fSimulationDraw; fSimulationDraw = 0; }
61  if (fRawDataDraw) { delete fRawDataDraw; fRawDataDraw = 0; }
62  if (fRecoBaseDraw) { delete fRecoBaseDraw; fRecoBaseDraw = 0; }
64  // if (fHitSelector) { delete fHitSelector; fHitSelector = 0; }
65  if (fPad) { delete fPad; fPad = 0; }
66  }
AnalysisBaseDrawer * fAnalysisBaseDraw
Drawer for analysisbase objects.
Definition: DrawingPad.h:60
RecoBaseDrawer * fRecoBaseDraw
Drawer for recobase objects.
Definition: DrawingPad.h:59
RawDataDrawer * fRawDataDraw
Drawer for raw data.
Definition: DrawingPad.h:58
TPad * fPad
The ROOT graphics pad.
Definition: DrawingPad.h:53
HeaderDrawer * fHeaderDraw
Drawer for event header info.
Definition: DrawingPad.h:54
SimulationDrawer * fSimulationDraw
Drawer for simulation objects.
Definition: DrawingPad.h:57

Member Function Documentation

AnalysisBaseDrawer * evd::DrawingPad::AnalysisBaseDraw ( )

Provide access to the drawer for AnalysisBase classes

Definition at line 132 of file DrawingPad.cxx.

References fAnalysisBaseDraw.

Referenced by evd::CalorPad::Draw().

133  {
134  if (fAnalysisBaseDraw==0) fAnalysisBaseDraw = new AnalysisBaseDrawer();
135  return fAnalysisBaseDraw;
136  }
AnalysisBaseDrawer * fAnalysisBaseDraw
Drawer for analysisbase objects.
Definition: DrawingPad.h:60
evd_tool::IExperimentDrawer * evd::DrawingPad::GeometryDraw ( )

Provide access to the drawer for the detector geometry

Definition at line 84 of file DrawingPad.cxx.

References fGeometryDraw, evd::EvdLayoutOptions::fParameterSet, and fhicl::ParameterSet::get().

Referenced by evd::Display3DPad::Draw().

85  {
86  if (fGeometryDraw==0)
87  {
89  const fhicl::ParameterSet& pset = layoutOptions->fParameterSet;
90 
91  fGeometryDraw = art::make_tool<evd_tool::IExperimentDrawer>(pset.get<fhicl::ParameterSet>("Experiment3DDrawer"));
92  }
93  return fGeometryDraw.get();
94  }
IExperimentDrawerPtr fGeometryDraw
Drawer for detector geometry.
Definition: DrawingPad.h:56
const fhicl::ParameterSet & fParameterSet
T get(std::string const &key) const
Definition: ParameterSet.h:231
HeaderDrawer * evd::DrawingPad::HeaderDraw ( )

Provide access to the drawer for the detector geometry

Definition at line 75 of file DrawingPad.cxx.

References fHeaderDraw.

Referenced by evd::HeaderPad::Draw().

76  {
77  if (fHeaderDraw==0) fHeaderDraw = new HeaderDrawer();
78  return fHeaderDraw;
79  }
HeaderDrawer * fHeaderDraw
Drawer for event header info.
Definition: DrawingPad.h:54
HitSelector * evd::DrawingPad::HitSelectorGet ( )
RawDataDrawer * evd::DrawingPad::RawDataDraw ( )

Provide access to the drawer for the RawData classes

Definition at line 109 of file DrawingPad.cxx.

References fRawDataDraw.

Referenced by evd::TQPad::BookHistogram(), evd::TQPad::Draw(), evd::TWireProjPad::Draw(), evd::TWireProjPad::ShowFull(), and evd::TWireProjPad::TWireProjPad().

110  {
111  if (fRawDataDraw==0) fRawDataDraw = new RawDataDrawer();
112  return fRawDataDraw;
113  }
RawDataDrawer * fRawDataDraw
Drawer for raw data.
Definition: DrawingPad.h:58
RecoBaseDrawer * evd::DrawingPad::RecoBaseDraw ( )

Provide access to the drawer for RecoBase classes

Definition at line 120 of file DrawingPad.cxx.

References fRecoBaseDraw.

Referenced by evd::TQPad::Draw(), evd::Display3DPad::Draw(), evd::TWireProjPad::Draw(), evd::Ortho3DPad::Draw(), and evd::TWireProjPad::ShowFull().

121  {
122  if (fRecoBaseDraw==0) fRecoBaseDraw = new RecoBaseDrawer();
123  return fRecoBaseDraw;
124 
125  }
RecoBaseDrawer * fRecoBaseDraw
Drawer for recobase objects.
Definition: DrawingPad.h:59
SimulationDrawer * evd::DrawingPad::SimulationDraw ( )

Provide access to the drawer for the Simulation classes

Definition at line 99 of file DrawingPad.cxx.

References fSimulationDraw.

Referenced by evd::MCBriefPad::Draw(), evd::Display3DPad::Draw(), evd::TWireProjPad::Draw(), and evd::Ortho3DPad::Draw().

100  {
101  if (fSimulationDraw==0) fSimulationDraw = new SimulationDrawer();
102  return fSimulationDraw;
103 
104  }
SimulationDrawer * fSimulationDraw
Drawer for simulation objects.
Definition: DrawingPad.h:57

Member Data Documentation

AnalysisBaseDrawer* evd::DrawingPad::fAnalysisBaseDraw
protected

Drawer for analysisbase objects.

Definition at line 60 of file DrawingPad.h.

Referenced by AnalysisBaseDraw(), and ~DrawingPad().

IExperimentDrawerPtr evd::DrawingPad::fGeometryDraw
protected

Drawer for detector geometry.

Definition at line 56 of file DrawingPad.h.

Referenced by GeometryDraw().

HeaderDrawer* evd::DrawingPad::fHeaderDraw
protected

Drawer for event header info.

Definition at line 54 of file DrawingPad.h.

Referenced by HeaderDraw(), and ~DrawingPad().

RawDataDrawer* evd::DrawingPad::fRawDataDraw
protected

Drawer for raw data.

Definition at line 58 of file DrawingPad.h.

Referenced by RawDataDraw(), and ~DrawingPad().

RecoBaseDrawer* evd::DrawingPad::fRecoBaseDraw
protected

Drawer for recobase objects.

Definition at line 59 of file DrawingPad.h.

Referenced by RecoBaseDraw(), and ~DrawingPad().

SimulationDrawer* evd::DrawingPad::fSimulationDraw
protected

Drawer for simulation objects.

Definition at line 57 of file DrawingPad.h.

Referenced by SimulationDraw(), and ~DrawingPad().


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