Logo ROOT   6.30.04
Reference Guide
 All Namespaces Files Pages
TEveProjectionAxes.h
Go to the documentation of this file.
1 // @(#)root/eve:$Id$
2 // Author: Matevz Tadel 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_TEveProjectionAxes
13 #define ROOT_TEveProjectionAxes
14 
15 #include "TNamed.h"
16 #include "TAtt3D.h"
17 #include "TAttBBox.h"
18 #include "TAttAxis.h"
19 
20 #include "TEveElement.h"
21 
22 class TEveProjectionManager;
23 
24 class TEveProjectionAxes : public TEveElement,
25  public TNamed,
26  public TAtt3D,
27  public TAttBBox,
28  public TAttAxis
29 {
30  friend class TEveProjectionAxesGL;
31 
32 public:
33  enum ELabMode { kPosition, kValue };
34  enum EAxesMode { kHorizontal, kVertical, kAll};
35 
36 private:
37  TEveProjectionAxes(const TEveProjectionAxes&); // Not implemented
38  TEveProjectionAxes& operator=(const TEveProjectionAxes&); // Not implemented
39 
40 protected:
41  TEveProjectionManager* fManager; // Model object.
42 
43  Bool_t fUseColorSet;
44 
45  ELabMode fLabMode; // Division of distorted space.
46  EAxesMode fAxesMode; // Axis vertical/hotrizontal orientation.
47 
48  Bool_t fDrawCenter; // Draw center of distortion.
49  Bool_t fDrawOrigin; // Draw origin.
50 
51 
52 public:
53  TEveProjectionAxes(TEveProjectionManager* m, Bool_t useColorSet = kTRUE);
54  virtual ~TEveProjectionAxes();
55 
56  TEveProjectionManager* GetManager() { return fManager; }
57 
58  void SetLabMode(ELabMode x) { fLabMode = x; }
59  ELabMode GetLabMode() const { return fLabMode;}
60  void SetAxesMode(EAxesMode x) { fAxesMode = x; }
61  EAxesMode GetAxesMode() const { return fAxesMode; }
62 
63  void SetDrawCenter(Bool_t x) { fDrawCenter = x; }
64  Bool_t GetDrawCenter() const { return fDrawCenter; }
65  void SetDrawOrigin(Bool_t x) { fDrawOrigin = x; }
66  Bool_t GetDrawOrigin() const { return fDrawOrigin; }
67 
68  virtual void Paint(Option_t* option="");
69  virtual void ComputeBBox();
70 
71  virtual const TGPicture* GetListTreeIcon(Bool_t open=kFALSE);
72 
73  ClassDef(TEveProjectionAxes, 0); // Class to draw scales in non-linear projections.
74 };
75 
76 #endif