71 Double_t x1,y1,xc,yc,r1,r2,xold,yold;
76 x0 =
gPad->AbsPixeltoX(px);
79 y0 =
gPad->AbsPixeltoY(py);
85 xold =
gPad->AbsPixeltoX(px);
86 yold =
gPad->AbsPixeltoY(py);
127 x1 =
gPad->AbsPixeltoX(px);
128 y1 =
gPad->AbsPixeltoY(py);
143 gROOT->SetEditorMode();
158 static Int_t pxold, pyold;
159 static Int_t px0, py0;
165 x0 =
gPad->AbsPixeltoX(px);
166 y0 =
gPad->AbsPixeltoY(py);
168 pxold = px; pyold = py;
177 x1 =
gPad->AbsPixeltoX(pxold);
178 y1 =
gPad->AbsPixeltoY(pyold);
225 fgCArc->SetStartPoint(x1, y1);
226 fgCArc->SetRadius(radius);
257 gROOT->SetEditorMode();
272 static Int_t px1old, py1old, px2old, py2old;
273 static Int_t px1, py1, px2, py2, pxl, pyl, pxt, pyt;
281 while ((obj = next())) {
292 px1 =
gPad->XtoAbsPixel(
gPad->GetX1());
293 py1 =
gPad->YtoAbsPixel(
gPad->GetY1());
294 px2 =
gPad->XtoAbsPixel(
gPad->GetX2());
295 py2 =
gPad->YtoAbsPixel(
gPad->GetY2());
296 px1old = px; py1old = py;
332 gROOT->SetEditorMode();
333 if (xup <= xlow || yup <= ylow)
return;
335 if (newpad->IsZombie())
break;
336 newpad->SetFillColor(
gStyle->GetPadColor());
338 auto canvas =
gPad->GetCanvas();
373 gROOT->SetEditorMode();
385 }
else if (isprint(py)) {
397 x0 =
gPad->AbsPixeltoX(px);
398 y0 =
gPad->AbsPixeltoY(py);
402 xold =
gPad->AbsPixeltoX(px);
403 yold =
gPad->AbsPixeltoY(py);
405 xp0 =
gPad->PadtoX(x0);
406 xp1 =
gPad->PadtoX(xold);
407 yp0 =
gPad->PadtoY(y0);
408 yp1 =
gPad->PadtoY(yold);
559 gROOT->SetEditorMode();
572 static Int_t pxnew, pynew, pxold, pyold, dp;
574 static Int_t npoints = 0;
585 gPad->PadtoY(
gPad->AbsPixeltoY(pynew)));
588 xnew =
gPad->PadtoX(
gPad->AbsPixeltoX(pxnew));
589 ynew =
gPad->PadtoY(
gPad->AbsPixeltoY(pynew));
591 pxold =
gPad->XtoAbsPixel(xold);
592 pyold =
gPad->YtoAbsPixel(yold);
606 gROOT->SetEditorMode();
617 gPad->PadtoY(
gPad->AbsPixeltoY(pynew)));
635 gROOT->SetEditorMode();
645 gPad->PadtoY(
gPad->AbsPixeltoY(pynew)));
673 gROOT->SetEditorMode();
686 }
else if (isprint(py)) {
704 x =
gPad->AbsPixeltoX(px);
705 y =
gPad->AbsPixeltoY(py);
714 gROOT->SetEditorMode();
int Int_t
Signed integer 4 bytes (int).
double Double_t
Double 8 bytes.
static Option_t * GetDefaultOption()
static Float_t GetDefaultArrowSize()
static void Pave(Int_t event, Int_t px, Int_t py, Int_t mode)
Create a new pavetext in gPad.
static TPavesText * fgPavesText
static TCurlyLine * fgCLine
static void Line(Int_t event, Int_t px, Int_t py, Int_t mode)
Create a new line/arrow in this gPad.
static TEllipse * fgEllipse
static void PolyLine(Int_t event, Int_t px, Int_t py, Int_t mode)
Create a new PolyLine in gPad.
static void Text(Int_t event, Int_t px, Int_t py, Int_t mode)
Create a new TLatex at the cursor position in gPad.
virtual ~TCreatePrimitives()
TCreatePrimitives destructor.
static void Ellipse(Int_t event, Int_t px, Int_t py, Int_t mode)
Create a new arc/ellipse in this gPad.
static TCurlyArc * fgCArc
static TGraph * fgPolyLine
static TPaveText * fgPaveText
static TPaveLabel * fgPaveLabel
TCreatePrimitives()
TCreatePrimitives default constructor.
static void Pad(Int_t event, Int_t px, Int_t py, Int_t)
Create a new pad in gPad.
static TDiamond * fgDiamond
static Double_t GetDefaultWaveLength()
static Double_t GetDefaultAmplitude()
static Double_t GetDefaultWaveLength()
static Double_t GetDefaultAmplitude()
@ kClipFrame
Clip to the frame boundary.
Use the TLine constructor to create a simple line.
void Draw(Option_t *option="") override
Draw this marker with its current attributes.
Mother of all ROOT objects.
virtual Bool_t InheritsFrom(const char *classname) const
Returns kTRUE if object inherits from class "classname".
The most important graphics class in the ROOT system.
A Pave (see TPave) with a text centered in the Pave.
A TBox with a bordersize and a shadow option.
A PaveText (see TPaveText) with several stacked paves.
TString & Insert(Ssiz_t pos, const char *s)
TString & Replace(Ssiz_t pos, Ssiz_t n, const char *s)
const char * Data() const
TString & Remove(Ssiz_t pos)
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString.
TVirtualPad is an abstract base class for the Pad and Canvas classes.
virtual TVirtualPad * cd(Int_t subpadnumber=0)=0
Short_t Max(Short_t a, Short_t b)
Returns the largest of a and b.
Double_t Sqrt(Double_t x)
Returns the square root of x.
LongDouble_t Power(LongDouble_t x, LongDouble_t y)
Returns x raised to the power y.
Short_t Min(Short_t a, Short_t b)
Returns the smallest of a and b.
Short_t Abs(Short_t d)
Returns the absolute value of parameter Short_t d.