test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
CmsShowCommon.h
Go to the documentation of this file.
1 #ifndef Fireworks_Core_CmsShowCommon_h
2 #define Fireworks_Core_CmsShowCommon_h
3 // -*- C++ -*-
4 //
5 // Package: Core
6 // Class : CmsShowCommon
7 //
16 //
17 // Original Author: Alja Mrak-Tadel
18 // Created: Fri Sep 10 14:51:07 CEST 2010
19 //
20 
21 #include <sigc++/signal.h>
22 #include <sigc++/sigc++.h>
23 
24 #include "Rtypes.h"
25 #include "TGLUtil.h"
26 
33 
34 class CmsShowCommonPopup;
35 class FWColorManager;
36 namespace fireworks
37 {
38 class Context;
39 }
40 
42 {
43  friend class CmsShowCommonPopup;
44 
45 public:
47  virtual ~CmsShowCommon();
48 
49  // ---------- const member functions ---------------------
50  virtual void addTo(FWConfiguration&) const;
51 
52  // ---------- static member functions --------------------
53 
54  // ---------- member functions ---------------------------
55  virtual void setFrom(const FWConfiguration&);
56 
57  void setTrackBreakMode();
58  void setDrawBreakMarkers();
59 
60  int gamma() { return m_gamma.value(); }
61  void setGamma();
62  void switchBackground();
63  void permuteColors();
64  void randomizeColors();
65  void loopPalettes();
66 
67  void setGeomColor(FWGeomColorIndex, Color_t);
68  void setGeomTransparency(int val, bool projected);
69 
70  FWViewEnergyScale* getEnergyScale() const { return m_energyScale.get(); }
71 
72  const TGLColorSet& getLightColorSet() const { return m_lightColorSet; }
73  const TGLColorSet& getDarkColorSet() const { return m_darkColorSet; }
74 
75 
76  UChar_t getProjTrackBreaking() const { return m_trackBreak.value(); }
77  bool getRnrPTBMarkers() const { return m_drawBreakPoints.value(); }
78 
80 
81 protected:
82  const FWColorManager* colorManager() const;
83  void setPalette();
84  // ---------- member data --------------------------------
85 
86 
89 
92 
93  // general colors
94  mutable FWLongParameter m_backgroundColor; // can be set via Ctr+b key binding
97 
98  // geom colors
102 
103  TGLColorSet m_lightColorSet;
104  TGLColorSet m_darkColorSet;
105 
106  std::auto_ptr<FWViewEnergyScale> m_energyScale;
107 
108 
109 private:
110  CmsShowCommon(const CmsShowCommon&); // stop default
111  const CmsShowCommon& operator=(const CmsShowCommon&); // stop default
112 
113 };
114 
115 
116 #endif
const CmsShowCommon & operator=(const CmsShowCommon &)
TGLColorSet m_lightColorSet
bool getRnrPTBMarkers() const
Definition: CmsShowCommon.h:77
FWBoolParameter m_drawBreakPoints
Definition: CmsShowCommon.h:91
FWLongParameter m_backgroundColor
Definition: CmsShowCommon.h:94
FWGeomColorIndex
void setTrackBreakMode()
FWLongParameter * m_geomColors[kFWGeomColorSize]
const FWColorManager * colorManager() const
FWLongParameter m_gamma
Definition: CmsShowCommon.h:95
void setGeomTransparency(int val, bool projected)
virtual ~CmsShowCommon()
void randomizeColors()
UChar_t getProjTrackBreaking() const
Definition: CmsShowCommon.h:76
const TGLColorSet & getLightColorSet() const
Definition: CmsShowCommon.h:72
void setGeomColor(FWGeomColorIndex, Color_t)
fireworks::Context * m_context
Definition: CmsShowCommon.h:88
void switchBackground()
FWLongParameter m_geomTransparency3D
void setDrawBreakMarkers()
FWLongParameter m_geomTransparency2D
Definition: CmsShowCommon.h:99
FWViewEnergyScale * getEnergyScale() const
Definition: CmsShowCommon.h:70
std::auto_ptr< FWViewEnergyScale > m_energyScale
virtual void addTo(FWConfiguration &) const
CmsShowCommonPopup * m_view
Definition: CmsShowCommon.h:87
const TGLColorSet & getDarkColorSet() const
Definition: CmsShowCommon.h:73
void permuteColors()
TGLColorSet m_darkColorSet
virtual void setFrom(const FWConfiguration &)
FWEnumParameter m_trackBreak
Definition: CmsShowCommon.h:90
void setView(CmsShowCommonPopup *x)
Definition: CmsShowCommon.h:79
CmsShowCommon(fireworks::Context *)
FWEnumParameter m_palette
Definition: CmsShowCommon.h:96