TCurlyLine
class description - source file - inheritance tree
public:
TCurlyLine TCurlyLine()
TCurlyLine TCurlyLine(Float_t x1, Float_t y1, Float_t x2, Float_t y2, Float_t tl = .05, Float_t rad = .02)
TCurlyLine TCurlyLine(TCurlyLine&)
virtual void ~TCurlyLine()
virtual void Build()
static TClass* Class()
virtual Int_t DistancetoPrimitive(Int_t px, Int_t py)
virtual void ExecuteEvent(Int_t event, Int_t px, Int_t py)
Float_t GetAmplitude()
Bool_t GetCurly()
Float_t GetEndX()
Float_t GetEndY()
Float_t GetStartX()
Float_t GetStartY()
Float_t GetWaveLength()
virtual TClass* IsA() const
virtual void SavePrimitive(ofstream& out, Option_t*)
virtual void SetAmplitude(Float_t x)
virtual void SetCurly()
virtual void SetEndPoint(Float_t x2, Float_t y2)
virtual void SetStartPoint(Float_t x1, Float_t y1)
virtual void SetWaveLength(Float_t WaveLength)
virtual void SetWavy()
virtual void ShowMembers(TMemberInspector& insp, char* parent)
virtual void Streamer(TBuffer& b)
protected:
Float_t fX1 start x, center for arc
Float_t fY1 start y, center for arc
Float_t fX2 end x
Float_t fY2 end y
Float_t fWaveLength wavelength of sinusoid in percent of pad height
Float_t fAmplitude amplitude of sinusoid in percent of pad height
Int_t fNsteps used internally (controls precision)
Bool_t fIsCurly true: Gluon, false: Gamma
public:
static const enum TObject:: kTooShort
See also
-
TCurlyArc
This class implements curly or wavy polylines typically used to draw Feynman diagrams.
Amplitudes and wavelengths may be specified in the constructors,
via commands or interactively from popup menus.
The class make use of TPolyLine by inheritance, ExecuteEvent methods
are highly inspired from the methods used in TPolyLine and TArc.
The picture below has been generated by the tutorial feynman.
/*
*/
________________________________________________________________________
TCurlyLine(Float_t x1, Float_t y1, Float_t x2, Float_t y2, Float_t tl, Float_t rad)
create a new TCurlyLine with starting point (x1, y1), end point (x2,y2)
The wavelength and amplitude are given in percent of the pad height
void Build()
*-*-*-*-*-*-*-*-*-*-*Create a curly (Gluon) or wavy (Gamma) line*-*-*-*-*-*
*-* ===========================================
Int_t DistancetoPrimitive(Int_t px, Int_t py)
*-*-*-*-*-*-*-*-*-*-*Compute distance from point px,py to a line*-*-*-*-*-*
*-* ===========================================
void ExecuteEvent(Int_t event, Int_t px, Int_t py)
*-*-*-*-*-*-*-*-*-*-*Execute action corresponding to one event*-*-*-*
*-* =========================================
This member function is called when a TCurlyLine is clicked with the locator
If Left button clicked on one of the line end points, this point
follows the cursor until button is released.
if Middle button clicked, the line is moved parallel to itself
until the button is released.
void SavePrimitive(ofstream &out, Option_t *)
Save primitive as a C++ statement(s) on output stream out
void SetCurly()
void SetWavy()
void SetWaveLength(Float_t x)
void SetAmplitude(Float_t x)
void SetStartPoint(Float_t x, Float_t y)
void SetEndPoint(Float_t x, Float_t y)
Inline Functions
TCurlyLine TCurlyLine(Float_t x1, Float_t y1, Float_t x2, Float_t y2, Float_t tl = .05, Float_t rad = .02)
Bool_t GetCurly()
Float_t GetWaveLength()
Float_t GetAmplitude()
Float_t GetStartX()
Float_t GetEndX()
Float_t GetStartY()
Float_t GetEndY()
TClass* Class()
TClass* IsA() const
void ShowMembers(TMemberInspector& insp, char* parent)
void Streamer(TBuffer& b)
TCurlyLine TCurlyLine(TCurlyLine&)
void ~TCurlyLine()
Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
ROOT page - Class index - Top of the page
This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.