Logo ROOT   6.08/07
Reference Guide
TGeoVolumeEditor.h
Go to the documentation of this file.
1 // @(#):$Id$
2 // Author: M.Gheata
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2002, 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 #ifndef ROOT_TGeoVolumeEditor
13 #define ROOT_TGeoVolumeEditor
14 
15 //////////////////////////////////////////////////////////////////////////
16 // //
17 // TGeoVolumeEditor //
18 // //
19 // Editor for a TGeoVolume. //
20 // //
21 //////////////////////////////////////////////////////////////////////////
22 
23 #ifndef ROOT_TGButton
24 #include "TGWidget.h"
25 #endif
26 #ifndef ROOT_TGeoGedFrame
27 #include "TGeoGedFrame.h"
28 #endif
29 
30 class TGeoManager;
31 class TGeoVolume;
32 class TGeoShape;
33 class TGeoMedium;
34 class TGeoMaterial;
35 class TGeoMatrix;
36 class TGTextEntry;
37 class TGNumberEntry;
38 class TGTab;
39 class TGComboBox;
40 class TGTextButton;
41 class TGPictureButton;
42 class TGCheckButton;
43 class TGRadioButton;
44 class TGShutter;
45 class TGShutterItem;
46 class TGeoTabManager;
47 
49 
50 protected:
51 
52  TGeoManager *fGeometry; // Selected geometry manager
53  TGeoVolume *fVolume; // Volume object
54  Bool_t fIsModified; // Flag that volume was modified
55  Bool_t fIsAssembly; // Flag that the volume is an assembly
56  Bool_t fIsDivided; // Flag that the volume is divided
57  TGShutter *fCategories; // Categories shutter
58  TGTextEntry *fVolumeName; // Volume name text entry
59 // TGComboBox *fShapeList; // All-shapes combo box
60  TGeoShape *fSelectedShape; // Selected shape
61  TGLabel *fLSelShape; // Selected shape label
62  TGPictureButton *fBSelShape; // Button for selecting a shape
63 // TGComboBox *fMediaList; // All-media combo box
64  TGeoMedium *fSelectedMedium; // Selected medium
65  TGLabel *fLSelMedium; // Selected medium label
66  TGPictureButton *fBSelMedium; // Button for selecting a medium
67 // TGComboBox *fVolumeList; // All-volume combo box
68  TGeoVolume *fSelectedVolume; // Selected volume
69  TGLabel *fLSelVolume; // Selected volume label
70  TGPictureButton *fBSelVolume; // Button for selecting a volume
71 // TGComboBox *fMatrixList; // All-matrix combo box
72  TGeoMatrix *fSelectedMatrix; // Selected matrix
73  TGLabel *fLSelMatrix; // Selected matrix label
74  TGPictureButton *fBSelMatrix; // Button for selecting a matrix
75  TGNumberEntry *fCopyNumber; // Node copy number
76  TGTextButton *fAddNode; // Button for adding a node
77  TGTextButton *fEditShape; // Check button for shape editing
78  TGTextButton *fEditMedium; // Check button for medium editing
79  TGComboBox *fNodeList; // Daughters combo box
80  TGTextButton *fEditMatrix; // Button for editing the position of a daughter
81  TGTextButton *fRemoveNode; // Button for removing a daughter
82  TGCheckButton *fBVis[2]; // Buttons for setting vis. on/off
83  TGRadioButton *fBView[3]; // Radio for selecting view options
84  TGCheckButton *fBRaytrace; // Raytracing on/off
85  TGCheckButton *fBAuto; // Check button for auto vis level
86  TGNumberEntry *fEVisLevel; // Number entry for visibility level
87  TGTextButton *fApplyDiv; // Button for applying division settings
88  TGTextEntry *fDivName; // Division volume name text entry
89  TGRadioButton *fBDiv[3]; // Radio for selecting division type
90  TGNumberEntry *fEDivFrom; // Number entry for division start
91  TGNumberEntry *fEDivStep; // Number entry for division step
92  TGNumberEntry *fEDivN; // Number entry for division Nslices
93 
94  virtual void ConnectSignals2Slots(); // Connect the signals to the slots
95 
96 public:
97  TGeoVolumeEditor(const TGWindow *p = 0,
98  Int_t width = 140, Int_t height = 30,
99  UInt_t options = kChildFrame,
101  virtual ~TGeoVolumeEditor();
102  virtual void SetModel(TObject *obj);
103  virtual void ActivateBaseClassEditors(TClass* cl);
104 
105  void DoAddNode();
106  void DoVolumeName();
107  void DoSelectShape();
108  void DoSelectMedium();
109  void DoSelectMatrix();
110  void DoSelectVolume();
111  void DoEditShape();
112  void DoEditMedium();
113  void DoEditMatrix();
114  void DoRemoveNode();
115  void DoVisVolume();
116  void DoVisDaughters();
117  void DoVisAuto();
118  void DoVisLevel();
119  void DoViewAll();
120  void DoViewLeaves();
121  void DoViewOnly();
122  void DoDivSelAxis();
123  void DoDivFromTo();
124  void DoDivStep();
125  void DoDivN();
126  void DoDivName();
127  void DoApplyDiv();
128  void DoRaytrace();
129 
130  ClassDef(TGeoVolumeEditor,0) // TGeoVolume editor
131 };
132 
133 #endif
TGeoVolume * fSelectedVolume
void DoDivN()
Handle division N modification.
TGeoMedium * fSelectedMedium
void DoRemoveNode()
Remove a daughter.
virtual ~TGeoVolumeEditor()
Destructor.
void DoRaytrace()
Slot for raytracing.
virtual void ConnectSignals2Slots()
Connect signals to slots.
The manager class for any TGeo geometry.
Definition: TGeoManager.h:38
void DoDivSelAxis()
Change division axis and preserve number of slices.
Definition: TGTab.h:66
Geometrical transformation package.
Definition: TGeoMatrix.h:40
void DoSelectMatrix()
Select a matrix for positioning.
TGTextButton * fApplyDiv
void DoSelectShape()
Select a new shape.
TGeoVolume, TGeoVolumeMulti, TGeoVolumeAssembly are the volume classes.
Definition: TGeoVolume.h:61
void DoVisAuto()
Slot for setting visibility depth auto.
TGeoMatrix * fSelectedMatrix
TGNumberEntry * fEVisLevel
void DoAddNode()
Add a daughter.
TGTextEntry * fDivName
Base class describing materials.
Definition: TGeoMaterial.h:35
int Int_t
Definition: RtypesCore.h:41
bool Bool_t
Definition: RtypesCore.h:59
void DoVolumeName()
Modify volume name.
void DoEditMedium()
Edit the medium of the volume.
void DoViewLeaves()
Slot for viewing last leaves only.
TGeoVolume * fVolume
void DoDivName()
Modify division name.
TGTextButton * fEditMedium
TGNumberEntry * fEDivStep
virtual void SetModel(TObject *obj)
Connect to the picked volume.
TGComboBox * fNodeList
#define ClassDef(name, id)
Definition: Rtypes.h:254
ULong_t Pixel_t
Definition: GuiTypes.h:41
static Pixel_t GetDefaultFrameBackground()
Get default frame background.
Definition: TGFrame.cxx:665
TGTextButton * fEditMatrix
TGTextEntry * fVolumeName
void DoVisDaughters()
Slot for setting daughters visible/invisible.
void DoApplyDiv()
Apply current division settings.
TGeoVolumeEditor(const TGWindow *p=0, Int_t width=140, Int_t height=30, UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground())
Constructor for volume editor.
void DoVisLevel()
Slot for visibility level.
void DoVisVolume()
Slot for setting volume visible/invisible.
TGTextButton * fAddNode
TGShutter * fCategories
TGCheckButton * fBVis[2]
TGPictureButton * fBSelShape
Base abstract class for all shapes.
Definition: TGeoShape.h:27
void DoViewOnly()
Slot for viewing volume only.
TGCheckButton * fBAuto
unsigned int UInt_t
Definition: RtypesCore.h:42
The ROOT global object gROOT contains a list of all defined classes.
Definition: TClass.h:81
void DoEditMatrix()
Edit the position of the selected node.
TGPictureButton * fBSelMatrix
TGTextButton * fRemoveNode
virtual void ActivateBaseClassEditors(TClass *cl)
Add editors to fGedFrame and exclude TLineEditor.
TGRadioButton * fBDiv[3]
Media are used to store properties related to tracking and which are useful only when using geometry ...
Definition: TGeoMedium.h:25
void DoSelectMedium()
Select a new medium.
TGCheckButton * fBRaytrace
TGNumberEntry * fCopyNumber
Mother of all ROOT objects.
Definition: TObject.h:37
TGRadioButton * fBView[3]
TGTextButton * fEditShape
void DoDivFromTo()
Handle division range modification.
void DoEditShape()
Edit the shape of the volume.
void DoDivStep()
Handle division step modification.
TGPictureButton * fBSelVolume
void DoViewAll()
Slot for viewing volume and containers.
TGNumberEntry * fEDivN
TGPictureButton * fBSelMedium
TGNumberEntry * fEDivFrom
void DoSelectVolume()
Select a daughter volume.
TGeoManager * fGeometry
TGeoShape * fSelectedShape