Logo ROOT   6.10/09
Reference Guide
TGeoNodeEditor.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_TGeoNodeEditor
13 #define ROOT_TGeoNodeEditor
14 
15 //////////////////////////////////////////////////////////////////////////
16 // //
17 // TGeoNodeEditor //
18 // //
19 // Editor for a TGeoNode. //
20 // //
21 //////////////////////////////////////////////////////////////////////////
22 
23 #include "TGWidget.h"
24 #include "TGeoGedFrame.h"
25 
26 class TGeoNode;
27 class TGeoVolume;
28 class TGeoMatrix;
29 class TGTextEntry;
30 class TGNumberEntry;
31 class TGTab;
32 class TGComboBox;
33 class TGTextButton;
34 class TGPictureButton;
35 class TGCheckButton;
36 class TGeoTabManager;
37 
38 class TGeoNodeEditor : public TGeoGedFrame {
39 
40 protected:
41 
42  TGeoNode *fNode; // Node object
43 
44  Bool_t fIsEditable; // Flag that the medium can be changed
45  TGTextEntry *fNodeName; // Node name text entry
46  TGNumberEntry *fNodeNumber; // Copy number
47  TGeoVolume *fSelectedVolume; // Selected volume
48  TGLabel *fLSelVolume; // Selected volume label
49  TGPictureButton *fBSelVolume; // Button for selecting a volume
50  TGeoVolume *fSelectedMother; // Selected mother
51  TGLabel *fLSelMother; // Selected mother label
52  TGPictureButton *fBSelMother; // Button for selecting a mother volume
53  TGeoMatrix *fSelectedMatrix; // Selected matrix
54  TGLabel *fLSelMatrix; // Selected matrix label
55  TGPictureButton *fBSelMatrix; // Button for selecting a matrix
56  TGTextButton *fEditMother; // Check button for editing mother volume
57  TGTextButton *fEditVolume; // Check button for volume editing
58  TGTextButton *fEditMatrix; // Check button for matrix editing
59  TGTextButton *fApply; // Apply-Button to accept changes
60  TGTextButton *fCancel; // Cancel-Button
61  TGTextButton *fUndo; // Undo-Button
62 
63  virtual void ConnectSignals2Slots(); // Connect the signals to the slots
64 
65 public:
66  TGeoNodeEditor(const TGWindow *p = 0,
67  Int_t width = 140, Int_t height = 30,
68  UInt_t options = kChildFrame,
70  virtual ~TGeoNodeEditor();
71  virtual void SetModel(TObject *obj);
72 
73  void DoEditMother();
74  void DoEditVolume();
75  void DoEditMatrix();
76  void DoSelectMother();
77  void DoSelectVolume();
78  void DoSelectMatrix();
79  void DoNodeName();
80  void DoNodeNumber();
81  void DoApply();
82  void DoUndo();
83 
84  ClassDef(TGeoNodeEditor,0) // TGeoNode editor
85 };
86 
87 #endif
TGPictureButton * fBSelMatrix
TGeoVolume * fSelectedMother
TGTextButton * fEditVolume
TGTextButton * fApply
TGPictureButton * fBSelMother
TGeoVolume * fSelectedVolume
Definition: TGTab.h:62
Geometrical transformation package.
Definition: TGeoMatrix.h:38
TGTextButton * fCancel
TGeoMatrix * fSelectedMatrix
TGeoVolume, TGeoVolumeMulti, TGeoVolumeAssembly are the volume classes.
Definition: TGeoVolume.h:48
void DoEditMother()
Edit the mother volume.
void DoNodeNumber()
Change node copy number.
int Int_t
Definition: RtypesCore.h:41
bool Bool_t
Definition: RtypesCore.h:59
TGTextButton * fEditMother
virtual void SetModel(TObject *obj)
Connect to a editable object.
TGeoNode * fNode
void DoSelectMother()
Select the mother volume.
#define ClassDef(name, id)
Definition: Rtypes.h:297
ULong_t Pixel_t
Definition: GuiTypes.h:39
static Pixel_t GetDefaultFrameBackground()
Get default frame background.
Definition: TGFrame.cxx:665
TGLabel * fLSelVolume
TGTextButton * fEditMatrix
void DoEditMatrix()
Edit selected material.
void DoSelectMatrix()
Select the matrix.
virtual void ConnectSignals2Slots()
Connect signals to slots.
TGPictureButton * fBSelVolume
virtual ~TGeoNodeEditor()
Destructor.
TGTextButton * fUndo
unsigned int UInt_t
Definition: RtypesCore.h:42
void DoUndo()
Slot for undoing last operation.
TGLabel * fLSelMatrix
void DoSelectVolume()
Select the volume.
TGeoNodeEditor(const TGWindow *p=0, Int_t width=140, Int_t height=30, UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground())
Constructor for node editor.
TGLabel * fLSelMother
Mother of all ROOT objects.
Definition: TObject.h:37
A node represent a volume positioned inside another.They store links to both volumes and to the TGeoM...
Definition: TGeoNode.h:39
void DoEditVolume()
Edit selected volume.
void DoNodeName()
Change node name.
TGNumberEntry * fNodeNumber
void DoApply()
Slot for applying modifications.
TGTextEntry * fNodeName