Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
TCurlyLine.cxx
Go to the documentation of this file.
1// @(#)root/graf:$Id$
2// Author: Otto Schaile 20/11/99
3
4/*************************************************************************
5 * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
6 * All rights reserved. *
7 * *
8 * For the licensing terms see $ROOTSYS/LICENSE. *
9 * For the list of contributors see $ROOTSYS/README/CREDITS. *
10 *************************************************************************/
11
12/** \class TCurlyLine
13\ingroup BasicGraphics
14
15Implements curly or wavy polylines used to draw Feynman diagrams.
16
17Amplitudes and wavelengths may be specified in the constructors,
18via commands or interactively from popup menus.
19The class make use of TPolyLine by inheritance, ExecuteEvent methods
20are highly inspired from the methods used in TPolyLine and TArc.
21The picture below has been generated by the tutorial feynman.
22
23Begin_Macro(source)
24../../../tutorials/visualisation/graphics/feynman.C
25End_Macro
26*/
27
28#include "TCurlyLine.h"
29#include "TVirtualPad.h"
30#include "TVirtualX.h"
31#include "TMath.h"
32#include "TPoint.h"
33
34#include <iostream>
35
39
40
41////////////////////////////////////////////////////////////////////////////////
42/// Default constructor.
43
45{
46 fX1 = 0.;
47 fY1 = 0.;
48 fX2 = 0.;
49 fY2 = 0.;
50 fWaveLength = 0.;
51 fAmplitude = 0.;
53 fNsteps = 0;
54}
55
56////////////////////////////////////////////////////////////////////////////////
57/// Create a new TCurlyLine with starting point (x1, y1), end point (x2,y2).
58/// The wavelength and amplitude are given in percent of the pad height.
59
71
72////////////////////////////////////////////////////////////////////////////////
73/// Create a curly (Gluon) or wavy (Gamma) line.
74
76{
79
81 Double_t px1, py1, px2, py2;
82 if (gPad) {
83 Double_t ww = (Double_t)gPad->GetWw();
84 Double_t wh = (Double_t)gPad->GetWh();
85 Double_t pxrange = gPad->GetAbsWNDC()*ww;
86 Double_t pyrange = - gPad->GetAbsHNDC()*wh;
87 Double_t xrange = gPad->GetX2() - gPad->GetX1();
88 Double_t yrange = gPad->GetY2() - gPad->GetY1();
91 hPix = TMath::Max(gPad->GetAbsHNDC() * gPad->GetWh(), gPad->GetAbsWNDC() * gPad->GetWw());
92 px1 = gPad->XtoAbsPixel(fX1);
93 py1 = gPad->YtoAbsPixel(fY1);
94 px2 = gPad->XtoAbsPixel(fX2);
95 py2 = gPad->YtoAbsPixel(fY2);
96
97 lengthPix = TMath::Sqrt((px2-px1)*(px2-px1) + (py1-py2)*(py1-py2));
100 } else {
103 px1 = fX1;
104 py1 = fY1;
105 px2 = fX2;
106 py2 = fY2;
107 lengthPix = TMath::Sqrt((px2-px1)*(px2-px1) + (py1-py2)*(py1-py2));
108 }
109 // construct the curly / wavy line in pixel coordinates at angle 0
110 Double_t anglestep = 40;
114
115 // make sure there is a piece of straight line a both ends
116
118 // if (fIsCurly) lengthcycle += amplitudePix;
121 fNsteps = (Int_t)(anglestep * nperiods + anglestep / 2 + 4);
122 if (fNsteps < 2) fNsteps = 2;
124 Double_t *xv = GetX();
125 Double_t *yv = GetY();
126 xv[0] = 0; yv[0] = 0;
127 xv[1] = restlength; yv[1] = 0;
128 Double_t phase = 1.5 * TMath::Pi();
130 Int_t i;
131 for(i = 2; i < fNsteps-1; i++){
132 // distinguish between curly and wavy
133 if (fIsCurly) xv[i] = x0 + amplitudePix * TMath::Sin(phase);
134 else xv[i] = x0;
136 phase += phimaxle;
137 x0 += dx;
138 }
139 xv[fNsteps-1] = lengthPix; yv[fNsteps-1] = 0;
140
141 if (InheritsFrom("TCurlyArc")) return; // called by TCurlyArc
142
143 // rotate object and transform back to user coordinates
144 Double_t angle = TMath::ATan2(py2-py1, px2-px1);
145 if (angle < 0) angle += 2*TMath::Pi();
146
149 Double_t xx, yy;
150
151 for(i = 0; i < fNsteps; i++){
152 xx = xv[i] * cosang - yv[i] * sinang;
153 yy = xv[i] * sinang + yv[i] * cosang;
154 if (gPad) {
155 xx *= pixeltoX;
156 yy *= pixeltoY;
157 }
158 xv[i] = xx + fX1;
159 yv[i] = yy + fY1;
160 }
161 if (gPad) gPad->Modified();
162}
163
164////////////////////////////////////////////////////////////////////////////////
165/// Compute distance from point px,py to a line.
166
171
172////////////////////////////////////////////////////////////////////////////////
173/// Execute action corresponding to one event.
174///
175/// This member function is called when a TCurlyLine is clicked with the locator
176///
177/// If Left button clicked on one of the line end points, this point
178/// follows the cursor until button is released.
179///
180/// if Middle button clicked, the line is moved parallel to itself
181/// until the button is released.
182
184{
185 if (!gPad) return;
186
187 Int_t kMaxDiff = 20;
188 static Int_t d1,d2,px1,px2,py1,py2;
190 static Bool_t p1, p2, pL;
191 Int_t dx, dy;
192
193 Bool_t opaque = gPad->OpaqueMoving();
194
195 switch (event) {
196
197 case kArrowKeyPress:
198 case kButton1Down:
199 if (!opaque) {
200 gVirtualX->SetLineColor(-1);
201 TAttLine::Modify(); //Change line attributes only if necessary
202 }
203
204 // No break !!!
205
206 case kMouseMotion:
207
208 px1 = gPad->XtoAbsPixel(fX1);
209 py1 = gPad->YtoAbsPixel(fY1);
210 px2 = gPad->XtoAbsPixel(fX2);
211 py2 = gPad->YtoAbsPixel(fY2);
212
213 p1 = p2 = pL = kFALSE;
214
215 d1 = TMath::Abs(px1 - px) + TMath::Abs(py1-py); //simply take sum of pixels differences
216 if (d1 < kMaxDiff) { //*-*================>OK take point number 1
217 px1old = px1; py1old = py1;
218 p1 = kTRUE;
219 gPad->SetCursor(kPointer);
220 return;
221 }
222 d2 = TMath::Abs(px2 - px) + TMath::Abs(py2-py); //simply take sum of pixels differences
223 if (d2 < kMaxDiff) { //*-*================>OK take point number 2
224 px2old = px2; py2old = py2;
225 p2 = kTRUE;
226 gPad->SetCursor(kPointer);
227 return;
228 }
229
230 pL = kTRUE;
231 pxold = px; pyold = py;
232 gPad->SetCursor(kMove);
233
234 break;
235
236 case kArrowKeyRelease:
237 case kButton1Motion:
238
239 if (p1) {
240 if (!opaque) {
241 gVirtualX->DrawLine(px1old, py1old, px2, py2);
242 gVirtualX->DrawLine(px, py, px2, py2);
243 }
244 else this->SetStartPoint(gPad->AbsPixeltoX(px),gPad->AbsPixeltoY(py));
245 px1old = px;
246 py1old = py;
247 }
248 if (p2) {
249 if (!opaque) {
250 gVirtualX->DrawLine(px1, py1, px2old, py2old);
251 gVirtualX->DrawLine(px1, py1, px, py);
252 }
253 else this->SetEndPoint(gPad->AbsPixeltoX(px), gPad->AbsPixeltoY(py));
254 px2old = px;
255 py2old = py;
256 }
257 if (pL) {
258 if (!opaque) gVirtualX->DrawLine(px1, py1, px2, py2);
259 dx = px-pxold; dy = py-pyold;
260 px1 += dx; py1 += dy; px2 += dx; py2 += dy;
261 if (!opaque) gVirtualX->DrawLine(px1, py1, px2, py2);
262 pxold = px;
263 pyold = py;
264 if (opaque) {
265 this->SetStartPoint(gPad->AbsPixeltoX(px1),gPad->AbsPixeltoY(py1));
266 this->SetEndPoint(gPad->AbsPixeltoX(px2), gPad->AbsPixeltoY(py2));
267 }
268 }
269
270 if (opaque) {
271 if (p1) {
272 //check in which corner the BBox is edited
273 if (fX1>fX2) {
274 if (fY1>fY2)
275 gPad->ShowGuidelines(this, event, '2', true);
276 else
277 gPad->ShowGuidelines(this, event, '3', true);
278 }
279 else {
280 if (fY1>fY2)
281 gPad->ShowGuidelines(this, event, '1', true);
282 else
283 gPad->ShowGuidelines(this, event, '4', true);
284 }
285 }
286 if (p2) {
287 //check in which corner the BBox is edited
288 if (fX1>fX2) {
289 if (fY1>fY2)
290 gPad->ShowGuidelines(this, event, '4', true);
291 else
292 gPad->ShowGuidelines(this, event, '1', true);
293 }
294 else {
295 if (fY1>fY2)
296 gPad->ShowGuidelines(this, event, '3', true);
297 else
298 gPad->ShowGuidelines(this, event, '2', true);
299 }
300 }
301 if (pL) {
302 gPad->ShowGuidelines(this, event, 'i', true);
303 }
304 gPad->Modified(kTRUE);
305 gPad->Update();
306 }
307 break;
308
309 case kButton1Up:
310
311 if (opaque) {
312 gPad->ShowGuidelines(this, event);
313 } else {
314 if (p1) {
315 fX1 = gPad->AbsPixeltoX(px);
316 fY1 = gPad->AbsPixeltoY(py);
317 }
318 if (p2) {
319 fX2 = gPad->AbsPixeltoX(px);
320 fY2 = gPad->AbsPixeltoY(py);
321 }
322 if (pL) {
323 fX1 = gPad->AbsPixeltoX(px1);
324 fY1 = gPad->AbsPixeltoY(py1);
325 fX2 = gPad->AbsPixeltoX(px2);
326 fY2 = gPad->AbsPixeltoY(py2);
327 }
328 }
329 Build();
330 gPad->Modified();
331 if (!opaque) gVirtualX->SetLineColor(-1);
332 }
333}
334
335////////////////////////////////////////////////////////////////////////////////
336/// Save primitive as a C++ statement(s) on output stream out
337
339{
340 SavePrimitiveConstructor(out, Class(), "curlyline",
341 TString::Format("%g, %g, %g, %g, %g, %g", fX1, fY1, fX2, fY2, fWaveLength, fAmplitude));
342
343 SaveLineAttributes(out, "curlyline", 1, 1, 1);
344
345 if (!fIsCurly)
346 out << " curlyline->SetWavy();\n";
347
348 SavePrimitiveDraw(out, "curlyline", option);
349}
350
351////////////////////////////////////////////////////////////////////////////////
352/// Set curly.
353
355{
356 fIsCurly = kTRUE;
357 Build();
358}
359
360////////////////////////////////////////////////////////////////////////////////
361/// Set wavy.
362
364{
366 Build();
367}
368
369////////////////////////////////////////////////////////////////////////////////
370/// Set wave length.
371
377
378////////////////////////////////////////////////////////////////////////////////
379/// Set amplitude.
380
382{
383 fAmplitude = x;
384 Build();
385}
386
387////////////////////////////////////////////////////////////////////////////////
388/// Set start point.
389
391{
392 fX1 = x;
393 fY1 = y;
394 Build();
395}
396
397////////////////////////////////////////////////////////////////////////////////
398/// Set end point.
399
401{
402 fX2 = x;
403 fY2 = y;
404 Build();
405}
406
407////////////////////////////////////////////////////////////////////////////////
408/// Set default wave length.
409
414
415////////////////////////////////////////////////////////////////////////////////
416/// Set default amplitude.
417
422
423////////////////////////////////////////////////////////////////////////////////
424/// Set default "IsCurly".
425
430
431////////////////////////////////////////////////////////////////////////////////
432/// Get default wave length.
433
438
439////////////////////////////////////////////////////////////////////////////////
440/// Get default amplitude.
441
446
447////////////////////////////////////////////////////////////////////////////////
448/// Get default "IsCurly".
449
454
455////////////////////////////////////////////////////////////////////////////////
456/// Return the bounding Box of the CurlyLine
457
459{
460 Rectangle_t BBox{0,0,0,0};
461 if (gPad) {
462 Int_t px1 = gPad->XtoPixel(fX1);
463 Int_t px2 = gPad->XtoPixel(fX2);
464 Int_t py1 = gPad->YtoPixel(fY1);
465 Int_t py2 = gPad->YtoPixel(fY2);
466
467 if (px1 > px2) {
468 Int_t tmp = px1;
469 px1 = px2;
470 px2 = tmp;
471 }
472 if (py1 > py2) {
473 Int_t tmp = py1;
474 py1 = py2;
475 py2 = tmp;
476 }
477
478 BBox.fX = px1;
479 BBox.fY = py1;
480 BBox.fWidth = px2 - px1;
481 BBox.fHeight = py2 - py1;
482 }
483 return BBox;
484}
485
486////////////////////////////////////////////////////////////////////////////////
487/// Return the center of the BoundingBox as TPoint in pixels
488
490{
491 TPoint p(0,0);
492 if (gPad) {
493 p.SetX(gPad->XtoPixel(TMath::Min(fX1, fX2) + 0.5 * (TMath::Max(fX1, fX2) - TMath::Min(fX1, fX2))));
494 p.SetY(gPad->YtoPixel(TMath::Min(fY1, fY2) + 0.5 * (TMath::Max(fY1, fY2) - TMath::Min(fY1, fY2))));
495 }
496 return p;
497}
498
499////////////////////////////////////////////////////////////////////////////////
500/// Set center of the BoundingBox
501
503{
504 if (!gPad) return;
507 Double_t x1, x2, y1, y2;
508
509 if (fX2 > fX1) {
510 x1 = gPad->PixeltoX(p.GetX())-0.5*w;
511 x2 = gPad->PixeltoX(p.GetX())+0.5*w;
512 } else {
513 x2 = gPad->PixeltoX(p.GetX())-0.5*w;
514 x1 = gPad->PixeltoX(p.GetX())+0.5*w;
515 }
516 if (fY2 > fY1) {
517 y1 = gPad->PixeltoY(p.GetY()-gPad->VtoPixel(0))-0.5*h;
518 y2 = gPad->PixeltoY(p.GetY()-gPad->VtoPixel(0))+0.5*h;
519 } else {
520 y2 = gPad->PixeltoY(p.GetY()-gPad->VtoPixel(0))-0.5*h;
521 y1 = gPad->PixeltoY(p.GetY()-gPad->VtoPixel(0))+0.5*h;
522 }
523 this->SetStartPoint(x1, y1);
524 this->SetEndPoint(x2, y2);
525}
526
527////////////////////////////////////////////////////////////////////////////////
528/// Set X coordinate of the center of the BoundingBox
529
531{
532 if (!gPad) return;
534 if (fX2>fX1) {
535 this->SetStartPoint(gPad->PixeltoX(x)-0.5*w, fY1);
536 this->SetEndPoint(gPad->PixeltoX(x)+0.5*w, fY2);
537 }
538 else {
539 this->SetEndPoint(gPad->PixeltoX(x)-0.5*w, fY2);
540 this->SetStartPoint(gPad->PixeltoX(x)+0.5*w, fY1);
541 }
542}
543
544////////////////////////////////////////////////////////////////////////////////
545/// Set Y coordinate of the center of the BoundingBox
546
548{
549 if (!gPad) return;
551 if (fY2>fY1) {
552 this->SetStartPoint(fX1, gPad->PixeltoY(y-gPad->VtoPixel(0))-0.5*h);
553 this->SetEndPoint(fX2, gPad->PixeltoY(y-gPad->VtoPixel(0))+0.5*h);
554 }
555 else {
556 this->SetEndPoint(fX2, gPad->PixeltoY(y-gPad->VtoPixel(0))-0.5*h);
557 this->SetStartPoint(fX1, gPad->PixeltoY(y-gPad->VtoPixel(0))+0.5*h);
558 }
559}
560
561////////////////////////////////////////////////////////////////////////////////
562/// Set left hand side of BoundingBox to a value
563/// (resize in x direction on left)
564
566{
567 if (!gPad) return;
568 if (fX2>fX1)
569 this->SetStartPoint(gPad->PixeltoX(x), fY1);
570 else
571 this->SetEndPoint(gPad->PixeltoX(x), fY2);
572}
573
574////////////////////////////////////////////////////////////////////////////////
575/// Set right hands ide of BoundingBox to a value
576/// (resize in x direction on right)
577
579{
580 if (!gPad) return;
581 if (fX2>fX1)
582 this->SetEndPoint(gPad->PixeltoX(x), fY2);
583 else
584 this->SetStartPoint(gPad->PixeltoX(x), fY1);
585}
586
587////////////////////////////////////////////////////////////////////////////////
588/// Set top of BoundingBox to a value (resize in y direction on top)
589
591{
592 if (!gPad) return;
593 if (fY2>fY1)
594 this->SetEndPoint(fX2, gPad->PixeltoY(y - gPad->VtoPixel(0)));
595 else
596 this->SetStartPoint(fX1, gPad->PixeltoY(y - gPad->VtoPixel(0)));
597}
598
599////////////////////////////////////////////////////////////////////////////////
600/// Set bottom of BoundingBox to a value
601/// (resize in y direction on bottom)
602
604{
605 if (!gPad) return;
606 if (fY2>fY1)
607 this->SetStartPoint(fX1, gPad->PixeltoY(y - gPad->VtoPixel(0)));
608 else
609 this->SetEndPoint(fX2, gPad->PixeltoY(y - gPad->VtoPixel(0)));
610}
@ kMouseMotion
Definition Buttons.h:23
@ kArrowKeyRelease
Definition Buttons.h:21
@ kButton1Motion
Definition Buttons.h:20
@ kButton1Up
Definition Buttons.h:19
@ kArrowKeyPress
Definition Buttons.h:21
@ kButton1Down
Definition Buttons.h:17
@ kMove
Definition GuiTypes.h:374
@ kPointer
Definition GuiTypes.h:375
#define h(i)
Definition RSha256.hxx:106
bool Bool_t
Boolean (0=false, 1=true) (bool)
Definition RtypesCore.h:77
int Int_t
Signed integer 4 bytes (int)
Definition RtypesCore.h:59
constexpr Bool_t kFALSE
Definition RtypesCore.h:108
double Double_t
Double 8 bytes.
Definition RtypesCore.h:73
constexpr Bool_t kTRUE
Definition RtypesCore.h:107
const char Option_t
Option string (const char)
Definition RtypesCore.h:80
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
winID h TVirtualViewer3D TVirtualGLPainter p
Option_t Option_t option
Option_t Option_t TPoint TPoint const char x2
Option_t Option_t TPoint TPoint const char x1
Option_t Option_t TPoint TPoint angle
Option_t Option_t TPoint TPoint const char y2
Option_t Option_t TPoint TPoint const char y1
#define gPad
#define gVirtualX
Definition TVirtualX.h:337
virtual void Modify()
Change current line attributes if necessary.
Definition TAttLine.cxx:246
Int_t DistancetoLine(Int_t px, Int_t py, Double_t xp1, Double_t yp1, Double_t xp2, Double_t yp2)
Compute distance from point px,py to a line.
Definition TAttLine.cxx:210
virtual void SaveLineAttributes(std::ostream &out, const char *name, Int_t coldef=1, Int_t stydef=1, Int_t widdef=1)
Save line attributes as C++ statement(s) on output stream out.
Definition TAttLine.cxx:274
TCurlyLine()
Default constructor.
virtual void SetWaveLength(Double_t WaveLength)
Set wave length.
virtual void SetCurly()
Set curly.
static TClass * Class()
Double_t fY1
start y, center for arc
Definition TCurlyLine.h:23
virtual void SetAmplitude(Double_t x)
Set amplitude.
Double_t fWaveLength
wavelength of sinusoid in percent of pad height
Definition TCurlyLine.h:26
Double_t fAmplitude
amplitude of sinusoid in percent of pad height
Definition TCurlyLine.h:27
void SetBBoxY1(const Int_t y) override
Set top of BoundingBox to a value (resize in y direction on top)
virtual void SetStartPoint(Double_t x1, Double_t y1)
Set start point.
void SetBBoxX2(const Int_t x) override
Set right hands ide of BoundingBox to a value (resize in x direction on right)
Int_t fNsteps
used internally (controls precision)
Definition TCurlyLine.h:28
void SetBBoxCenter(const TPoint &p) override
Set center of the BoundingBox.
void SetBBoxY2(const Int_t y) override
Set bottom of BoundingBox to a value (resize in y direction on bottom)
Rectangle_t GetBBox() override
Return the bounding Box of the CurlyLine.
TPoint GetBBoxCenter() override
Return the center of the BoundingBox as TPoint in pixels.
static Double_t GetDefaultWaveLength()
Get default wave length.
static Bool_t GetDefaultIsCurly()
Get default "IsCurly".
virtual void Build()
Create a curly (Gluon) or wavy (Gamma) line.
void SavePrimitive(std::ostream &out, Option_t *="") override
Save primitive as a C++ statement(s) on output stream out.
static void SetDefaultAmplitude(Double_t Amplitude)
Set default amplitude.
static void SetDefaultWaveLength(Double_t WaveLength)
Set default wave length.
static Bool_t fgDefaultIsCurly
default curly type
Definition TCurlyLine.h:33
Double_t fY2
end y
Definition TCurlyLine.h:25
static Double_t GetDefaultAmplitude()
Get default amplitude.
virtual void SetEndPoint(Double_t x2, Double_t y2)
Set end point.
void SetBBoxX1(const Int_t x) override
Set left hand side of BoundingBox to a value (resize in x direction on left)
Double_t fX1
start x, center for arc
Definition TCurlyLine.h:22
static Double_t fgDefaultWaveLength
default wavelength
Definition TCurlyLine.h:31
void SetBBoxCenterX(const Int_t x) override
Set X coordinate of the center of the BoundingBox.
static void SetDefaultIsCurly(Bool_t IsCurly)
Set default "IsCurly".
virtual void SetWavy()
Set wavy.
static Double_t fgDefaultAmplitude
default amplitude
Definition TCurlyLine.h:32
Int_t DistancetoPrimitive(Int_t px, Int_t py) override
Compute distance from point px,py to a line.
Double_t fX2
end x
Definition TCurlyLine.h:24
void ExecuteEvent(Int_t event, Int_t px, Int_t py) override
Execute action corresponding to one event.
Bool_t fIsCurly
true: Gluon, false: Gamma
Definition TCurlyLine.h:29
void SetBBoxCenterY(const Int_t y) override
Set Y coordinate of the center of the BoundingBox.
virtual Bool_t InheritsFrom(const char *classname) const
Returns kTRUE if object inherits from class "classname".
Definition TObject.cxx:543
static void SavePrimitiveDraw(std::ostream &out, const char *variable_name, Option_t *option=nullptr)
Save invocation of primitive Draw() method Skipped if option contains "nodraw" string.
Definition TObject.cxx:822
static void SavePrimitiveConstructor(std::ostream &out, TClass *cl, const char *variable_name, const char *constructor_agrs="", Bool_t empty_line=kTRUE)
Save object constructor in the output stream "out".
Definition TObject.cxx:771
Double_t * GetX() const
Definition TPolyLine.h:54
Double_t * GetY() const
Definition TPolyLine.h:55
virtual void SetPolyLine(Int_t n)
Resize this polyline to size n.
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString.
Definition TString.cxx:2384
Double_t y[n]
Definition legend1.C:17
Double_t x[n]
Definition legend1.C:17
Short_t Max(Short_t a, Short_t b)
Returns the largest of a and b.
Definition TMathBase.h:251
Double_t ATan2(Double_t y, Double_t x)
Returns the principal value of the arc tangent of y/x, expressed in radians.
Definition TMath.h:657
Double_t Sqrt(Double_t x)
Returns the square root of x.
Definition TMath.h:673
Short_t Min(Short_t a, Short_t b)
Returns the smallest of a and b.
Definition TMathBase.h:199
Double_t Cos(Double_t)
Returns the cosine of an angle of x radians.
Definition TMath.h:605
constexpr Double_t Pi()
Definition TMath.h:40
Double_t Sin(Double_t)
Returns the sine of an angle of x radians.
Definition TMath.h:599
Short_t Abs(Short_t d)
Returns the absolute value of parameter Short_t d.
Definition TMathBase.h:124
Rectangle structure (maps to the X11 XRectangle structure)
Definition GuiTypes.h:361