00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012 #ifndef ROOT_TBox
00013 #define ROOT_TBox
00014
00015
00017
00018
00019
00020
00021
00023
00024 #ifndef ROOT_TObject
00025 #include "TObject.h"
00026 #endif
00027 #ifndef ROOT_TAttLine
00028 #include "TAttLine.h"
00029 #endif
00030 #ifndef ROOT_TAttFill
00031 #include "TAttFill.h"
00032 #endif
00033
00034 class TBox : public TObject, public TAttLine, public TAttFill {
00035
00036 private:
00037 TObject *fTip;
00038
00039 protected:
00040 Double_t fX1;
00041 Double_t fY1;
00042 Double_t fX2;
00043 Double_t fY2;
00044 Bool_t fResizing;
00045
00046 public:
00047 TBox();
00048 TBox(Double_t x1, Double_t y1,Double_t x2, Double_t y2);
00049 TBox(const TBox &box);
00050 virtual ~TBox();
00051 void Copy(TObject &box) const;
00052 virtual Int_t DistancetoPrimitive(Int_t px, Int_t py);
00053 virtual void Draw(Option_t *option="");
00054 virtual void DrawBox(Double_t x1, Double_t y1, Double_t x2, Double_t y2);
00055 virtual void ExecuteEvent(Int_t event, Int_t px, Int_t py);
00056 Bool_t IsBeingResized() const { return fResizing; }
00057 Double_t GetX1() const { return fX1; }
00058 Double_t GetX2() const { return fX2; }
00059 Double_t GetY1() const { return fY1; }
00060 Double_t GetY2() const { return fY2; }
00061 virtual void HideToolTip(Int_t event);
00062 virtual void ls(Option_t *option="") const;
00063 virtual void Paint(Option_t *option="");
00064 virtual void PaintBox(Double_t x1, Double_t y1, Double_t x2, Double_t y2, Option_t *option="");
00065 virtual void Print(Option_t *option="") const;
00066 virtual void SavePrimitive(ofstream &out, Option_t *option);
00067 virtual void SetX1(Double_t x1) {fX1=x1;}
00068 virtual void SetX2(Double_t x2) {fX2=x2;}
00069 virtual void SetY1(Double_t y1) {fY1=y1;}
00070 virtual void SetY2(Double_t y2) {fY2=y2;}
00071 virtual void SetToolTipText(const char *text, Long_t delayms = 1000);
00072
00073 ClassDef(TBox,2)
00074 };
00075
00076 #endif
00077