Logo ROOT   6.18/05
Reference Guide
TGeoTrapEditor.h
Go to the documentation of this file.
1// @(#):$Id$
2// Author: M.Gheata
3/*************************************************************************
4 * Copyright (C) 1995-2002, Rene Brun and Fons Rademakers. *
5 * All rights reserved. *
6 * *
7 * For the licensing terms see $ROOTSYS/LICENSE. *
8 * For the list of contributors see $ROOTSYS/README/CREDITS. *
9 *************************************************************************/
10
11#ifndef ROOT_TGeoTrapEditor
12#define ROOT_TGeoTrapEditor
13
14#include "TGWidget.h"
15#include "TGeoGedFrame.h"
16
17class TGeoTrap;
18class TGeoTabManager;
19class TGTextEntry;
20class TGNumberEntry;
21class TGTab;
22class TGComboBox;
23class TGTextButton;
24class TGCheckButton;
25class TString;
26
28
29protected:
30
31 Double_t fH1i; // Initial half length in y at low z
32 Double_t fBl1i; // Initial half length in x at low z and y low edge
33 Double_t fTl1i; // Initial half length in x at low z and y high edge
34 Double_t fDzi; // Initial Dz
35 Double_t fSci; // Initial scale factor for upper face
36 Double_t fAlpha1i; // Initial angle between centers of x edges an y axis at low z
37 Double_t fThetai; // Initial theta
38 Double_t fPhii; // Initial phi
39 TString fNamei; // Initial name
40 TGeoTrap *fShape; // Shape object
41 Bool_t fIsModified; // Flag that volume was modified
42 Bool_t fIsShapeEditable; // Flag that the shape can be changed
43
44 TGTextEntry *fShapeName; // Shape name text entry
45 TGNumberEntry *fEH1; // Number entry for H1
46 TGNumberEntry *fEBl1; // Number entry for Bl1
47 TGNumberEntry *fETl1; // Number entry for Tl1
48 TGNumberEntry *fESc1; // Number entry for lower scale
49 TGNumberEntry *fESc2; // Number entry for upper scale
50 TGNumberEntry *fEDz; // Number entry for DZ
51 TGNumberEntry *fEAlpha1; // Number entry for Alpha1
52 TGNumberEntry *fETheta; // Number entry for Theta
53 TGNumberEntry *fEPhi ; // Number entry for Theta
54 TGTextButton *fApply; // Apply-Button to accept changes
55 TGTextButton *fUndo; // Undo-Button
56 TGCompositeFrame *fBFrame; // Frame containing Apply/Undo
57 TGCheckButton *fDelayed; // Check button for delayed draw
58 TGCompositeFrame *fDFrame; // Frame containing Delayed draw
59
60 virtual void ConnectSignals2Slots(); // Connect the signals to the slots
61 Bool_t IsDelayed() const;
62
63public:
64 TGeoTrapEditor(const TGWindow *p = 0,
65 Int_t width = 140, Int_t height = 30,
66 UInt_t options = kChildFrame,
68 virtual ~TGeoTrapEditor();
69 virtual void SetModel(TObject *obj);
70
71 void DoH1();
72 void DoBl1();
73 void DoTl1();
74 void DoDz();
75 void DoSc1();
76 void DoSc2();
77 void DoAlpha1();
78 void DoTheta();
79 void DoPhi();
80 void DoModified();
81 void DoName();
82 virtual void DoApply();
83 virtual void DoUndo();
84
85 ClassDef(TGeoTrapEditor,0) // TGeoTrap editor
86};
87
89
90protected:
91
92 Double_t fTwisti; // Initial twist angle
93 TGNumberEntry *fETwist; // Number entry for H1
94
95public:
96 TGeoGtraEditor(const TGWindow *p = 0,
97 Int_t width = 140, Int_t height = 30,
98 UInt_t options = kChildFrame,
100 virtual ~TGeoGtraEditor();
101 virtual void SetModel(TObject *obj);
102
103 void DoTwist();
104 virtual void DoApply();
105 virtual void DoUndo();
106
107 ClassDef(TGeoGtraEditor,0) // TGeoTrap editor
108};
109
110#endif
ULong_t Pixel_t
Definition: GuiTypes.h:39
int Int_t
Definition: RtypesCore.h:41
unsigned int UInt_t
Definition: RtypesCore.h:42
bool Bool_t
Definition: RtypesCore.h:59
double Double_t
Definition: RtypesCore.h:55
#define ClassDef(name, id)
Definition: Rtypes.h:326
include TDocParser_001 C image html pict1_TDocParser_001 png width
Definition: TDocParser.cxx:121
@ kChildFrame
Definition: TGFrame.h:57
static Pixel_t GetDefaultFrameBackground()
Get default frame background.
Definition: TGFrame.cxx:665
Definition: TGTab.h:62
Common base class for geombuilder editors.
Definition: TGeoGedFrame.h:13
Editor for a TGeoGtra.
Double_t fTwisti
TGNumberEntry * fETwist
virtual void DoUndo()
Slot for undoing last operation.
virtual void SetModel(TObject *obj)
Connect to a given twisted trapezoid.
TGeoGtraEditor(const TGWindow *p=0, Int_t width=140, Int_t height=30, UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground())
Constructor for gtra editor.
virtual ~TGeoGtraEditor()
Destructor.
void DoTwist()
Change the twist angle.
virtual void DoApply()
Slot for applying current settings.
Manager for all editor tabs.
Editor for a TGeoTrap.
TGTextButton * fApply
TGNumberEntry * fEPhi
TGCompositeFrame * fDFrame
TGNumberEntry * fEBl1
void DoTl1()
Slot for Tl1.
void DoSc2()
Slot for H2.
void DoH1()
Slot for H1.
TGCheckButton * fDelayed
TGNumberEntry * fETl1
TGNumberEntry * fEDz
TGeoTrapEditor(const TGWindow *p=0, Int_t width=140, Int_t height=30, UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground())
Constructor for para editor.
virtual ~TGeoTrapEditor()
Destructor.
Bool_t fIsShapeEditable
virtual void DoUndo()
Slot for undoing last operation.
virtual void SetModel(TObject *obj)
Connect to the selected object.
TGTextEntry * fShapeName
TGNumberEntry * fEH1
void DoPhi()
Slot for phi.
virtual void ConnectSignals2Slots()
Connect signals to slots.
TGNumberEntry * fETheta
void DoName()
Slot for name.
void DoSc1()
Slot for H2.
Double_t fAlpha1i
TGCompositeFrame * fBFrame
void DoAlpha1()
Slot for alpha1.
TGNumberEntry * fESc2
void DoBl1()
Slot for Bl1.
virtual void DoApply()
Slot for applying current settings.
TGNumberEntry * fESc1
void DoDz()
Slot for Z.
void DoTheta()
Slot for theta.
void DoModified()
Slot for notifying modifications.
TGeoTrap * fShape
Bool_t IsDelayed() const
Check if shape drawing is delayed.
TGTextButton * fUndo
TGNumberEntry * fEAlpha1
Double_t fThetai
TRAP is a general trapezoid, i.e.
Definition: TGeoArb8.h:90
Mother of all ROOT objects.
Definition: TObject.h:37
Basic string class.
Definition: TString.h:131