File indexing completed on 2025-01-18 10:11:30
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012 #ifndef ROOT_TAttText
0013 #define ROOT_TAttText
0014
0015
0016 #include "Rtypes.h"
0017
0018 class TAttText {
0019
0020 protected:
0021 Float_t fTextAngle;
0022 Float_t fTextSize;
0023 Short_t fTextAlign;
0024 Color_t fTextColor;
0025 Font_t fTextFont;
0026
0027 public:
0028 TAttText();
0029 TAttText(Int_t align, Float_t angle, Color_t color, Style_t font, Float_t tsize);
0030 virtual ~TAttText();
0031 void Copy(TAttText &atttext) const;
0032 virtual Short_t GetTextAlign() const {return fTextAlign;}
0033 virtual Float_t GetTextAngle() const {return fTextAngle;}
0034 virtual Color_t GetTextColor() const {return fTextColor;}
0035 virtual Font_t GetTextFont() const {return fTextFont;}
0036 virtual Float_t GetTextSize() const {return fTextSize;}
0037 virtual Float_t GetTextSizePercent(Float_t size);
0038 virtual void Modify();
0039 virtual void ResetAttText(Option_t *toption="");
0040 virtual void SaveTextAttributes(std::ostream &out, const char *name, Int_t alidef=12, Float_t angdef=0, Int_t coldef=1, Int_t fondef=61, Float_t sizdef=1);
0041 virtual void SetTextAttributes();
0042 virtual void SetTextAlign(Short_t align=11) { fTextAlign = align;}
0043 virtual void SetTextAngle(Float_t tangle=0) { fTextAngle = tangle;}
0044 virtual void SetTextColor(Color_t tcolor=1) { fTextColor = tcolor;}
0045 virtual void SetTextColorAlpha(Color_t tcolor, Float_t talpha);
0046 virtual void SetTextFont(Font_t tfont=62) { fTextFont = tfont;}
0047 virtual void SetTextSize(Float_t tsize=1) { fTextSize = tsize;}
0048 virtual void SetTextSizePixels(Int_t npixels);
0049
0050 ClassDef(TAttText,2)
0051 };
0052
0053 enum ETextAlign {kHAlignLeft=10, kHAlignCenter=20, kHAlignRight=30,
0054 kVAlignBottom=1, kVAlignCenter=2, kVAlignTop=3};
0055
0056 #endif
0057