Warning, file /include/root/TGX11TTF.h was not indexed
or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013 #ifndef ROOT_TGX11TTF
0014 #define ROOT_TGX11TTF
0015
0016
0017 #include "TGX11.h"
0018
0019 #include "TTF.h"
0020
0021 #include "RConfigure.h"
0022
0023 #ifdef R__HAS_XFT
0024 class TXftFontHash;
0025 #endif
0026
0027 class TGX11TTF : public TGX11 {
0028
0029 private:
0030 enum EAlign { kNone, kTLeft, kTCenter, kTRight, kMLeft, kMCenter, kMRight,
0031 kBLeft, kBCenter, kBRight };
0032
0033 FT_Vector fAlign;
0034 #ifdef R__HAS_XFT
0035 TXftFontHash *fXftFontHash;
0036 #endif
0037
0038 void Align(void);
0039 void DrawImage(FT_Bitmap *source, ULong_t fore, ULong_t back, RXImage *xim,
0040 Int_t bx, Int_t by);
0041 Bool_t IsVisible(Int_t x, Int_t y, UInt_t w, UInt_t h);
0042 RXImage *GetBackground(Int_t x, Int_t y, UInt_t w, UInt_t h);
0043 void RenderString(Int_t x, Int_t y, ETextMode mode);
0044
0045 public:
0046 TGX11TTF(const TGX11 &org);
0047 ~TGX11TTF() override { }
0048
0049 Bool_t Init(void *display) override;
0050 void DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn,
0051 const char *text, ETextMode mode) override;
0052 void DrawText(Int_t x, Int_t y, Float_t angle, Float_t mgn,
0053 const wchar_t *text, ETextMode mode) override;
0054 void SetTextFont(Font_t fontnumber) override;
0055 Int_t SetTextFont(char *fontname, ETextSetMode mode) override;
0056 void SetTextSize(Float_t textsize) override;
0057
0058 #ifdef R__HAS_XFT
0059
0060
0061 FontStruct_t LoadQueryFont(const char *font_name) override;
0062 void DeleteFont(FontStruct_t fs) override;
0063 void DeleteGC(GContext_t gc) override;
0064 void DrawString(Drawable_t id, GContext_t gc, Int_t x, Int_t y, const char *s, Int_t len) override;
0065 Int_t TextWidth(FontStruct_t font, const char *s, Int_t len) override;
0066 void GetFontProperties(FontStruct_t font, Int_t &max_ascent, Int_t &max_descent) override;
0067 FontH_t GetFontHandle(FontStruct_t fs) override;
0068 FontStruct_t GetGCFont(GContext_t gc) override;
0069 void MapGCFont(GContext_t gc, FontStruct_t font) override;
0070 #endif
0071
0072 static void Activate();
0073
0074 ClassDefOverride(TGX11TTF,0)
0075 };
0076
0077 #endif