source: trunk/MagicSoft/Mars/mbase/MGMap.h@ 4076

Last change on this file since 4076 was 4058, checked in by tbretz, 22 years ago
*** empty log message ***
File size: 1.6 KB
Line 
1#ifndef MARS_MGMap
2#define MARS_MGMap
3
4#ifndef ROOT_GuiTypes
5#include <GuiTypes.h> // Drawable_t
6#endif
7#ifndef ROOT_TExMap
8#include <TExMap.h>
9#endif
10
11class TString;
12class TGToolTip;
13
14class MGMap : public TExMap
15{
16private:
17 // TGToolTip *fToolTip; //! The tooltip currently displayed
18
19 enum {
20 kIsOwner = BIT(14),
21 // kNoToolTips = BIT(15), // suppress tooltips
22 };
23
24 // void ShowToolTip(Int_t px, Int_t py, const char *txt);
25
26public:
27 MGMap(Int_t mapSize = 100);
28 ~MGMap();
29
30 void SetOwner(Bool_t o=kTRUE) { o ? SetBit(kIsOwner) : ResetBit(kIsOwner); }
31 void Add(TObject *k, TString *v=0);
32 void Delete(Option_t *opt = "");
33
34 // void SetNoToolTips(Bool_t b=kTRUE) { b ? SetBit(kNoToolTips) : ResetBit(kNoToolTips); } // *TOGGLE* *GETTER=HasNoToolTips
35 // Bool_t HasNoToolTips() const { return TestBit(kNoToolTips); }
36
37 void Paint(Option_t *o="");
38 void Paint(unsigned char *buf, int w, int h, Float_t scale);
39 //void Paint(Drawable_t id, Float_t scale);
40
41 Int_t Color(int col);
42
43 void DrawLine(TObject *o, unsigned char *buf, int w, int h, Double_t scale);
44 void DrawMarker(TObject *o, unsigned char *buf, int w, int h, Double_t scale);
45
46 //void EventInfo(Int_t event, Int_t px, Int_t py, TObject *selected);
47 TObject *PickObject(Int_t px, Int_t py, TString &str) const;
48 char *GetObjectInfo(Int_t px, Int_t py) const;
49 Int_t DistancetoPrimitive(Int_t px, Int_t py);
50
51 ClassDef(MGMap, 1) // Special TExMap supporting enhanced drawing and bitmap drawing
52};
53
54#endif
Note: See TracBrowser for help on using the repository browser.