12 #ifndef ROOT_TEveParamList
13 #define ROOT_TEveParamList
24 class TEveParamList :
public TEveElement,
28 friend class TEveParamListEditor;
33 Float_t fValue, fMin, fMax;
37 FloatConfig_t(TString name, Double_t value, Double_t min, Double_t max, Bool_t selector = kFALSE):
38 fValue(value), fMin(min), fMax(max), fName(name), fSelector(selector) {}
39 FloatConfig_t(): fValue(0), fMin(0), fMax(0), fName(
""), fSelector(kFALSE) {}
41 typedef std::vector<FloatConfig_t> FloatConfigVec_t;
42 typedef FloatConfigVec_t::iterator FloatConfigVec_i;
43 typedef FloatConfigVec_t::const_iterator FloatConfigVec_ci;
47 Int_t fValue, fMin, fMax;
51 IntConfig_t(TString name, Int_t value, Int_t min, Int_t max, Bool_t selector=kFALSE) :
52 fValue(value), fMin(min), fMax(max), fName(name), fSelector(selector) {}
53 IntConfig_t() : fValue(0), fMin(0), fMax(0), fName(
""), fSelector(kFALSE) {}
55 typedef std::vector<IntConfig_t> IntConfigVec_t;
56 typedef IntConfigVec_t::iterator IntConfigVec_i;
57 typedef IntConfigVec_t::const_iterator IntConfigVec_ci;
64 BoolConfig_t(TString name, Bool_t value): fValue(value), fName(name) {}
65 BoolConfig_t() : fValue(kFALSE), fName(
"") {}
67 typedef std::vector<BoolConfig_t> BoolConfigVec_t;
68 typedef BoolConfigVec_t::iterator BoolConfigVec_i;
69 typedef BoolConfigVec_t::const_iterator BoolConfigVec_ci;
72 TEveParamList(
const TEveParamList&);
73 TEveParamList& operator=(
const TEveParamList&);
77 FloatConfigVec_t fFloatParameters;
78 IntConfigVec_t fIntParameters;
79 BoolConfigVec_t fBoolParameters;
82 TEveParamList(
const char* n=
"TEveParamList",
const char* t=
"", Bool_t doColor=kFALSE);
83 virtual ~TEveParamList() {}
85 void AddParameter(
const FloatConfig_t& parameter) { fFloatParameters.push_back(parameter); }
86 void AddParameter(
const IntConfig_t& parameter) { fIntParameters.push_back(parameter); }
87 void AddParameter(
const BoolConfig_t& parameter) { fBoolParameters.push_back(parameter); }
89 const FloatConfigVec_t& GetFloatParameters() {
return fFloatParameters; }
90 const IntConfigVec_t& GetIntParameters() {
return fIntParameters; }
91 const BoolConfigVec_t& GetBoolParameters() {
return fBoolParameters; }
93 FloatConfig_t GetFloatParameter(
const TString& name);
94 IntConfig_t GetIntParameter (
const TString& name);
95 Bool_t GetBoolParameter (
const TString& name);
97 void ParamChanged(
const char* name);
99 ClassDef(TEveParamList, 0);
116 class TEveGDoubleValuator;
122 class TEveParamListEditor :
public TGedFrame
125 TEveParamListEditor(
const TEveParamListEditor&);
126 TEveParamListEditor& operator=(
const TEveParamListEditor&);
130 TGVerticalFrame *fParamFrame;
131 std::vector<TGNumberEntry*> fIntParameters;
132 std::vector<TGNumberEntry*> fFloatParameters;
133 std::vector<TGCheckButton*> fBoolParameters;
135 virtual void InitModel(TObject* obj);
138 TEveParamListEditor(
const TGWindow* p=0, Int_t width=170, Int_t height=30,
139 UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground());
140 virtual ~TEveParamListEditor() {}
142 virtual void SetModel(TObject* obj);
146 void DoFloatUpdate();
149 ClassDef(TEveParamListEditor, 0);