Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:11:30

0001 #ifndef Fireworks_Core_CmsShowCommonPopup_h
0002 #define Fireworks_Core_CmsShowCommonPopup_h
0003 
0004 #ifndef __CINT__
0005 #include <memory>
0006 #endif
0007 #include "GuiTypes.h"
0008 #include "TGFrame.h"
0009 #include "Fireworks/Core/interface/FWParameterSetterEditorBase.h"
0010 #ifndef __CINT__
0011 #include "Fireworks/Core/interface/FWColorManager.h"
0012 #endif
0013 
0014 class TGHSlider;
0015 class TGLabel;
0016 class TGComboBox;
0017 class TGTextButton;
0018 class TGCheckButton;
0019 class CmsShowCommon;
0020 class FWColorManager;
0021 class FWColorSelect;
0022 class FWParameterBase;
0023 class FWParameterSetterBase;
0024 
0025 class CmsShowCommonPopup : public TGTransientFrame, public FWParameterSetterEditorBase {
0026 public:
0027   CmsShowCommonPopup(CmsShowCommon*, const TGWindow* p = nullptr, UInt_t w = 1, UInt_t h = 1);
0028   ~CmsShowCommonPopup() override;
0029 
0030   // ---------- member functions ---------------------------
0031 
0032   void CloseWindow() override { UnmapWindow(); }
0033 
0034   void switchBackground();
0035   void permuteColors();
0036   void randomizeColors();
0037 
0038   void changeGeomColor(Color_t);
0039   void changeGeomTransparency2D(int);
0040   void changeGeomTransparency3D(int);
0041   void changeSelectionColorSet(Color_t);
0042   void colorSetChanged();
0043   void setPaletteGUI();
0044 
0045   TGComboBox* getCombo() { return m_combo; }
0046   ClassDefOverride(CmsShowCommonPopup, 0);
0047 
0048 private:
0049   CmsShowCommonPopup(const CmsShowCommonPopup&);
0050   const CmsShowCommonPopup& operator=(const CmsShowCommonPopup&);
0051 
0052   TGFrame* makeSetter(TGCompositeFrame* frame, FWParameterBase* param);
0053   void getColorSetColors(int& hci, int& sci);
0054   // ---------- member data --------------------------------
0055 
0056   CmsShowCommon* m_common;
0057 
0058   TGTextButton* m_backgroundButton;
0059   TGHSlider* m_gammaSlider;
0060   TGTextButton* m_gammaButton;
0061 #ifndef __CINT__
0062   FWColorSelect* m_colorSelectWidget[kFWGeomColorSize];
0063   FWColorSelect* m_colorRnrCtxHighlightWidget;
0064   FWColorSelect* m_colorRnrCtxSelectWidget;
0065   std::vector<std::shared_ptr<FWParameterSetterBase> > m_setters;
0066 #endif
0067   TGComboBox* m_combo;
0068 };
0069 
0070 #endif