From 6d8e981b51458f0381031fe240f5215db9906622 Mon Sep 17 00:00:00 2001 From: dsinclair Date: Wed, 13 Apr 2016 10:52:11 -0700 Subject: Cleanup IFPF_* interfaces. This CL removes the IFPF_DeviceModule, IFPF_FontMgr and IFPF_Font interfaces in favour of their concrete classes. BUG=pdfium:467 Review URL: https://codereview.chromium.org/1881043004 --- core/fxge/android/fpf_skiafont.h | 49 ++++++++++++++++++++-------------------- 1 file changed, 25 insertions(+), 24 deletions(-) (limited to 'core/fxge/android/fpf_skiafont.h') diff --git a/core/fxge/android/fpf_skiafont.h b/core/fxge/android/fpf_skiafont.h index c21bdeadc4..59172a5385 100644 --- a/core/fxge/android/fpf_skiafont.h +++ b/core/fxge/android/fpf_skiafont.h @@ -11,35 +11,35 @@ #if _FX_OS_ == _FX_ANDROID_ -#include "core/fxge/include/fpf.h" #include "core/fxge/include/fx_font.h" class CFPF_SkiaFontDescriptor; class CFPF_SkiaFontMgr; -class CFPF_SkiaFont : public IFPF_Font { + +typedef struct FPF_HFONT_ { void* pData; } * FPF_HFONT; + +class CFPF_SkiaFont { public: CFPF_SkiaFont(); - ~CFPF_SkiaFont() override; - - // IFPF_Font - void Release() override; - IFPF_Font* Retain() override; - FPF_HFONT GetHandle() override; - CFX_ByteString GetFamilyName() override; - CFX_WideString GetPsName() override; - uint32_t GetFontStyle() const override { return m_dwStyle; } - uint8_t GetCharset() const override { return m_uCharset; } - int32_t GetGlyphIndex(FX_WCHAR wUnicode) override; - int32_t GetGlyphWidth(int32_t iGlyphIndex) override; - int32_t GetAscent() const override; - int32_t GetDescent() const override; - FX_BOOL GetGlyphBBox(int32_t iGlyphIndex, FX_RECT& rtBBox) override; - FX_BOOL GetBBox(FX_RECT& rtBBox) override; - int32_t GetHeight() const override; - int32_t GetItalicAngle() const override; - uint32_t GetFontData(uint32_t dwTable, - uint8_t* pBuffer, - uint32_t dwSize) override; + ~CFPF_SkiaFont(); + + void Release(); + CFPF_SkiaFont* Retain(); + + FPF_HFONT GetHandle(); + CFX_ByteString GetFamilyName(); + CFX_WideString GetPsName(); + uint32_t GetFontStyle() const { return m_dwStyle; } + uint8_t GetCharset() const { return m_uCharset; } + int32_t GetGlyphIndex(FX_WCHAR wUnicode); + int32_t GetGlyphWidth(int32_t iGlyphIndex); + int32_t GetAscent() const; + int32_t GetDescent() const; + FX_BOOL GetGlyphBBox(int32_t iGlyphIndex, FX_RECT& rtBBox); + FX_BOOL GetBBox(FX_RECT& rtBBox); + int32_t GetHeight() const; + int32_t GetItalicAngle() const; + uint32_t GetFontData(uint32_t dwTable, uint8_t* pBuffer, uint32_t dwSize); FX_BOOL InitFont(CFPF_SkiaFontMgr* pFontMgr, CFPF_SkiaFontDescriptor* pFontDes, @@ -55,6 +55,7 @@ class CFPF_SkiaFont : public IFPF_Font { uint8_t m_uCharset; uint32_t m_dwRefCount; }; -#endif + +#endif // _FX_OS_ == _FX_ANDROID_ #endif // CORE_FXGE_ANDROID_FPF_SKIAFONT_H_ -- cgit v1.2.3