Logo ROOT   6.30.04
Reference Guide
 All Namespaces Files Pages
TEveTransEditor.h
Go to the documentation of this file.
1 // @(#)root/eve:$Id$
2 // Authors: Matevz Tadel & Alja Mrak-Tadel: 2006, 2007
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2007, 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_TEveTransEditor
13 #define ROOT_TEveTransEditor
14 
15 #include "TGedFrame.h"
16 
17 class TGCheckButton;
18 class TGTextButton;
19 
20 class TEveTrans;
21 class TEveGTriVecValuator;
22 
23 
24 class TEveTransSubEditor : public TGVerticalFrame
25 {
26  TEveTransSubEditor(const TEveTransSubEditor&); // Not implemented
27  TEveTransSubEditor& operator=(const TEveTransSubEditor&); // Not implemented
28 
29 protected:
30  TEveTrans *fTrans;
31 
32  TGHorizontalFrame *fTopHorFrame;
33 
34  TGCheckButton *fUseTrans;
35  TGCheckButton *fEditTrans;
36 
37  TGVerticalFrame *fEditTransFrame;
38 
39  TEveGTriVecValuator *fPos;
40  TEveGTriVecValuator *fRot;
41  TEveGTriVecValuator *fScale;
42 
43  TGCheckButton *fAutoUpdate;
44  TGTextButton *fUpdate;
45 
46 public:
47  TEveTransSubEditor(TGWindow* p);
48  virtual ~TEveTransSubEditor() {}
49 
50  void SetModel(TEveTrans* t);
51  void SetTransFromData();
52 
53  void UseTrans(); //*SIGNAL*
54  void TransChanged(); //*SIGNAL*
55 
56  void DoUseTrans();
57  void DoEditTrans();
58  void DoTransChanged();
59 
60  TEveGTriVecValuator* GetPosValuator(){ return fPos;}
61  TEveGTriVecValuator* GetRotValuator(){ return fRot;}
62  TEveGTriVecValuator* GetScaleValuator(){ return fScale;}
63 
64  ClassDef(TEveTransSubEditor, 0); // Sub-editor for TEveTrans class.
65 };
66 
67 
68 class TEveTransEditor : public TGedFrame
69 {
70 private:
71  TEveTransEditor(const TEveTransEditor&); // Not implemented
72  TEveTransEditor& operator=(const TEveTransEditor&); // Not implemented
73 
74 protected:
75  TEveTrans *fM; // Model object.
76  TEveTransSubEditor *fSE; // Actual editor widget.
77 
78 public:
79  TEveTransEditor(const TGWindow* p=0, Int_t width=170, Int_t height=30, UInt_t options = kChildFrame, Pixel_t back=GetDefaultFrameBackground());
80  virtual ~TEveTransEditor() {}
81 
82  virtual void SetModel(TObject* obj);
83 
84  ClassDef(TEveTransEditor, 0); // Editor for TEveTrans class.
85 };
86 
87 #endif