1 #ifndef ALIMUONPAINTERINTERFACEHELPER_H
2 #define ALIMUONPAINTERINTERFACEHELPER_H
4 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
10 /// \class AliMUONPainterInterfaceHelper
11 /// \brief Helper class to ease building a GUI with button groups...
13 // Author Laurent Aphecetche, Subatech
24 class AliMUONPainterInterfaceHelper : public TObject
27 AliMUONPainterInterfaceHelper();
28 virtual ~AliMUONPainterInterfaceHelper();
30 static void AddRadioButton(TGButtonGroup& bg,
33 Bool_t select=kFALSE);
35 static void AddCheckButton(TGButtonGroup& bg,
38 Bool_t select=kFALSE);
40 /// Id of first button in a group
41 static Int_t ButtonStartingId() { return 1; }
43 static void ClearButtons(TGButtonGroup& bg);
47 static void Copy(const TGButtonGroup& src, TGButtonGroup& dest);
51 static void Dump(const TGButtonGroup& bg);
53 static TGButton* FindButtonByName(const TGButtonGroup& bg, const TString& name);
55 static TGButton* FindButtonByUserData(const TGButtonGroup& bg, const void* userData);
57 static TGButton* FindDownButton(const TGButtonGroup& bg);
59 static void SetBackgroundColor(const char* resourceBaseName, TGWindow& window);
61 static void SetState(TGButtonGroup& bg, Bool_t state);
63 static void Select(TGButtonGroup& bg, const TString& buttonName, Bool_t emit=kFALSE);
65 static void Unselect(TGButtonGroup& bg, const TString& buttonName, Bool_t emit=kFALSE);
67 static void RemoveButton(TGButtonGroup& bg, const TGButton* button);
69 ClassDef(AliMUONPainterInterfaceHelper,1) // Helper class for TGButtonGroup manipulation