ROOT  6.07/01
Reference Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
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 #ifndef ROOT_TGButton
24 #include "TGWidget.h"
25 #endif
26 #ifndef ROOT_TGeoGedFrame
27 #include "TGeoGedFrame.h"
28 #endif
29 
30 class TGeoNode;
31 class TGeoVolume;
32 class TGeoMatrix;
33 class TGTextEntry;
34 class TGNumberEntry;
35 class TGTab;
36 class TGComboBox;
37 class TGTextButton;
38 class TGPictureButton;
39 class TGCheckButton;
40 class TGeoTabManager;
41 
42 class TGeoNodeEditor : public TGeoGedFrame {
43 
44 protected:
45 
46  TGeoNode *fNode; // Node object
47 
48  Bool_t fIsEditable; // Flag that the medium can be changed
49  TGTextEntry *fNodeName; // Node name text entry
50  TGNumberEntry *fNodeNumber; // Copy number
51  TGeoVolume *fSelectedVolume; // Selected volume
52  TGLabel *fLSelVolume; // Selected volume label
53  TGPictureButton *fBSelVolume; // Button for selecting a volume
54  TGeoVolume *fSelectedMother; // Selected mother
55  TGLabel *fLSelMother; // Selected mother label
56  TGPictureButton *fBSelMother; // Button for selecting a mother volume
57  TGeoMatrix *fSelectedMatrix; // Selected matrix
58  TGLabel *fLSelMatrix; // Selected matrix label
59  TGPictureButton *fBSelMatrix; // Button for selecting a matrix
60  TGTextButton *fEditMother; // Check button for editing mother volume
61  TGTextButton *fEditVolume; // Check button for volume editing
62  TGTextButton *fEditMatrix; // Check button for matrix editing
63  TGTextButton *fApply; // Apply-Button to accept changes
64  TGTextButton *fCancel; // Cancel-Button
65  TGTextButton *fUndo; // Undo-Button
66 
67  virtual void ConnectSignals2Slots(); // Connect the signals to the slots
68 
69 public:
70  TGeoNodeEditor(const TGWindow *p = 0,
71  Int_t width = 140, Int_t height = 30,
72  UInt_t options = kChildFrame,
74  virtual ~TGeoNodeEditor();
75  virtual void SetModel(TObject *obj);
76 
77  void DoEditMother();
78  void DoEditVolume();
79  void DoEditMatrix();
80  void DoSelectMother();
81  void DoSelectVolume();
82  void DoSelectMatrix();
83  void DoNodeName();
84  void DoNodeNumber();
85  void DoApply();
86  void DoUndo();
87 
88  ClassDef(TGeoNodeEditor,0) // TGeoNode editor
89 };
90 
91 #endif
TGPictureButton * fBSelMatrix
TGeoVolume * fSelectedMother
TGTextButton * fEditVolume
TGTextButton * fApply
TGPictureButton * fBSelMother
TGeoVolume * fSelectedVolume
Definition: TGTab.h:66
TGTextButton * fCancel
TGeoMatrix * fSelectedMatrix
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.
ULong_t Pixel_t
Definition: GuiTypes.h:41
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.
ClassDef(TGedFrame, 0)
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:58
void DoEditVolume()
Edit selected volume.
void DoNodeName()
Change node name.
TGNumberEntry * fNodeNumber
TObject * obj
void DoApply()
Slot for applying modifications.
TGTextEntry * fNodeName