00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012 #ifndef ROOT_TGToolTip
00013 #define ROOT_TGToolTip
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027 #ifndef ROOT_TGFrame
00028 #include "TGFrame.h"
00029 #endif
00030
00031 class TGLabel;
00032 class TTimer;
00033 class TVirtualPad;
00034 class TBox;
00035
00036
00037 class TGToolTip : public TGCompositeFrame {
00038
00039 private:
00040 TGLabel *fLabel;
00041 TGLayoutHints *fL1;
00042 TTimer *fDelay;
00043 const TGFrame *fWindow;
00044 const TVirtualPad *fPad;
00045 const TBox *fBox;
00046 Int_t fX;
00047 Int_t fY;
00048
00049 TGToolTip(const TGToolTip&);
00050 TGToolTip& operator=(const TGToolTip&);
00051
00052 public:
00053 TGToolTip(const TGWindow *p = 0, const TGFrame *f = 0, const char *text = 0, Long_t delayms = 350);
00054 TGToolTip(const TGWindow *p, const TBox *b, const char *text, Long_t delayms);
00055 TGToolTip(const TBox *b, const char *text, Long_t delayms);
00056 TGToolTip(Int_t x, Int_t y, const char *text, Long_t delayms);
00057 virtual ~TGToolTip();
00058
00059 virtual void DrawBorder();
00060
00061 Bool_t HandleTimer(TTimer *t);
00062 void Show(Int_t x, Int_t y);
00063 void Hide();
00064 void Reset();
00065 void Reset(const TVirtualPad *parent);
00066 void SetText(const char *new_text);
00067 void SetPosition(Int_t x, Int_t y);
00068 void SetDelay(Long_t delayms);
00069 const TGString *GetText() const;
00070
00071 ClassDef(TGToolTip,0)
00072 };
00073
00074 #endif