summaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2015-11-24 13:43:47 -0800
committerTom Sepez <tsepez@chromium.org>2015-11-24 13:43:47 -0800
commite00cef685e1e4799e3ede59bb3bf18fe17ec6f19 (patch)
tree57232e6684b1949f2c997adff5c083d1177c791a /core
parent55dd8546ebc365b3778b40ba9d82879f581503e1 (diff)
downloadpdfium-e00cef685e1e4799e3ede59bb3bf18fe17ec6f19.tar.xz
Re-virtualize CFX_UnicodeEncoding.
It's not required on master, but it costs very little and makes XFA line up more closely. Also make InitFTLibrary() public for the same reasons. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1475643003 .
Diffstat (limited to 'core')
-rw-r--r--core/include/fxge/fx_font.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/core/include/fxge/fx_font.h b/core/include/fxge/fx_font.h
index 277b45ebaa..95b036e0bc 100644
--- a/core/include/fxge/fx_font.h
+++ b/core/include/fxge/fx_font.h
@@ -123,11 +123,11 @@ class CFX_Font {
class CFX_UnicodeEncoding {
public:
explicit CFX_UnicodeEncoding(CFX_Font* pFont);
- ~CFX_UnicodeEncoding();
+ virtual ~CFX_UnicodeEncoding();
- FX_DWORD GlyphFromCharCode(FX_DWORD charcode);
+ virtual FX_DWORD GlyphFromCharCode(FX_DWORD charcode);
- private:
+ protected:
// Unowned, not nullptr.
CFX_Font* m_pFont;
};
@@ -175,6 +175,8 @@ class CFX_FontMgr {
CFX_FontMgr();
~CFX_FontMgr();
+ void InitFTLibrary();
+
FXFT_Face GetCachedFace(const CFX_ByteString& face_name,
int weight,
FX_BOOL bItalic,
@@ -210,8 +212,6 @@ class CFX_FontMgr {
FXFT_Library GetFTLibrary() const { return m_FTLibrary; }
private:
- void InitFTLibrary();
-
nonstd::unique_ptr<CFX_FontMapper> m_pBuiltinMapper;
std::map<CFX_ByteString, CTTFontDesc*> m_FaceMap;
FXFT_Library m_FTLibrary;