16 #include <TMultiGraph.h>
34 #define SPL_NPADMAX (10)
58 SatPlot(
const string aName,
const int aNx=800,
const int aNy=494);
76 Wpad[aPadIndex]->UseCurrentStyle();
77 Wpad[aPadIndex]->Modified();
78 Wpad[aPadIndex]->Update();
88 inline void Draw(TObject *aObj,
const string aOptions=
"",
const int aPadIndex=0){
89 Wpad[aPadIndex]->cd();
90 aObj->Draw(aOptions.c_str());
91 Wpad[aPadIndex]->UseCurrentStyle();
92 Wpad[aPadIndex]->Modified();
93 Wpad[aPadIndex]->Update();
102 void Print(
const string aFileName,
const double aScaleFactor=1.0);
115 inline void SetLogx(
const int aValue,
const int aPadIndex=0){
116 Wpad[aPadIndex]->SetLogx(aValue);
117 Wpad[aPadIndex]->Modified();
118 Wpad[aPadIndex]->Update();
132 inline void SetLogy(
const int aValue,
const int aPadIndex=0){
133 Wpad[aPadIndex]->SetLogy(aValue);
134 Wpad[aPadIndex]->Modified();
135 Wpad[aPadIndex]->Update();
149 inline void SetLogz(
const int aValue,
const int aPadIndex=0){
150 Wpad[aPadIndex]->SetLogz(aValue);
151 Wpad[aPadIndex]->Modified();
152 Wpad[aPadIndex]->Update();
161 inline void SetGridx(
const int aValue=1,
const int aPadIndex=0){
162 Wpad[aPadIndex]->SetGridx(aValue);
163 Wpad[aPadIndex]->Modified();
164 Wpad[aPadIndex]->Update();
173 inline void SetGridy(
const int aValue=1,
const int aPadIndex=0){
174 Wpad[aPadIndex]->SetGridy(aValue);
175 Wpad[aPadIndex]->Modified();
176 Wpad[aPadIndex]->Update();
188 int AddPad(
const double aX0,
const double aY0,
const double aRx,
const double aRy);
199 inline void ResizePad(
const double aX0,
const double aY0,
const double aX1,
const double aY1,
const int aPadIndex=0){
200 Wpad[aPadIndex]->SetPad(aX0, aY0, aX1, aY1);
201 Wpad[aPadIndex]->Modified();
202 Wpad[aPadIndex]->Update();
210 inline void Clear(
const int aPadIndex=0){ Wpad[aPadIndex]->Clear(); };
218 inline double GetPadXmax(
const int aPadIndex=0){
return Wpad[aPadIndex]->GetUxmax(); };
226 inline double GetPadXmin(
const int aPadIndex=0){
return Wpad[aPadIndex]->GetUxmin(); };
234 inline double GetPadYmax(
const int aPadIndex=0){
return Wpad[aPadIndex]->GetUymax(); };
242 inline double GetPadYmin(
const int aPadIndex=0){
return Wpad[aPadIndex]->GetUymin(); };
This module offers C++ utility functions.
#define SPL_NPADMAX
Maximum number of working pads.
Definition: SatPlot.h:34
Draw and print ROOT graphical objects.
Definition: SatPlot.h:41
TStyle * Wstyle
working style.
Definition: SatPlot.h:250
int npads
number of working pads.
Definition: SatPlot.h:254
void Draw(TObject *aObj, const string aOptions="", const int aPadIndex=0)
Draws a ROOT object.
Definition: SatPlot.h:88
void SetGridx(const int aValue=1, const int aPadIndex=0)
Sets/Unsets grid for X.
Definition: SatPlot.h:161
double GetPadXmin(const int aPadIndex=0)
Returns the minimum x-coordinate value visible on the pad.
Definition: SatPlot.h:226
void UseCurrentStyle(const int aPadIndex=0)
Force a copy of current style for all objects in canvas.
Definition: SatPlot.h:75
void Clear(const int aPadIndex=0)
Clears pad.
Definition: SatPlot.h:210
void SetLogy(const int aValue, const int aPadIndex=0)
Sets Linear/Log scale for Y.
Definition: SatPlot.h:132
void SetLogz(const int aValue, const int aPadIndex=0)
Sets Linear/Log scale for Z.
Definition: SatPlot.h:149
int randid
random integer id.
Definition: SatPlot.h:242
void SetGridy(const int aValue=1, const int aPadIndex=0)
Sets/Unsets grid for Y.
Definition: SatPlot.h:173
void ResizePad(const double aX0, const double aY0, const double aX1, const double aY1, const int aPadIndex=0)
Resizes a pad.
Definition: SatPlot.h:199
string srandid
random string id.
Definition: SatPlot.h:247
double GetPadXmax(const int aPadIndex=0)
Returns the maximum x-coordinate value visible on the pad.
Definition: SatPlot.h:218
SatPlot(const string aName, const int aNx=800, const int aNy=494)
Constructor of the SatPlot class.
TCanvas * Wcan
working canvas.
Definition: SatPlot.h:253
void SetLogx(const int aValue, const int aPadIndex=0)
Sets Linear/Log scale for the X axis.
Definition: SatPlot.h:115
double GetPadYmin(const int aPadIndex=0)
Returns the minimum y-coordinate value visible on the pad.
Definition: SatPlot.h:242
double GetPadYmax(const int aPadIndex=0)
Returns the maximum y-coordinate value visible on the pad.
Definition: SatPlot.h:234