Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(25)

Side by Side Diff: core/fxge/include/cfx_fontmapper.h

Issue 2239703003: Refactoring cfx_fontmapper (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Nit Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « core/fxge/ge/cfx_fontmapper.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 PDFium Authors. All rights reserved. 1 // Copyright 2016 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 6
7 #ifndef CORE_FXGE_INCLUDE_CFX_FONTMAPPER_H_ 7 #ifndef CORE_FXGE_INCLUDE_CFX_FONTMAPPER_H_
8 #define CORE_FXGE_INCLUDE_CFX_FONTMAPPER_H_ 8 #define CORE_FXGE_INCLUDE_CFX_FONTMAPPER_H_
9 9
10 #include <memory> 10 #include <memory>
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 static const size_t MM_FACE_COUNT = 2; 48 static const size_t MM_FACE_COUNT = 2;
49 static const size_t FOXIT_FACE_COUNT = 14; 49 static const size_t FOXIT_FACE_COUNT = 14;
50 50
51 CFX_ByteString GetPSNameFromTT(void* hFont); 51 CFX_ByteString GetPSNameFromTT(void* hFont);
52 CFX_ByteString MatchInstalledFonts(const CFX_ByteString& norm_name); 52 CFX_ByteString MatchInstalledFonts(const CFX_ByteString& norm_name);
53 FXFT_Face UseInternalSubst(CFX_SubstFont* pSubstFont, 53 FXFT_Face UseInternalSubst(CFX_SubstFont* pSubstFont,
54 int iBaseFont, 54 int iBaseFont,
55 int italic_angle, 55 int italic_angle,
56 int weight, 56 int weight,
57 int picthfamily); 57 int picthfamily);
58 FXFT_Face GetCachedTTCFace(void* hFont,
59 const uint32_t tableTTCF,
60 uint32_t ttc_size,
61 uint32_t font_size);
62 FXFT_Face GetCachedFace(void* hFont,
63 CFX_ByteString SubstName,
64 int weight,
65 FX_BOOL bItalic,
66 uint32_t font_size);
58 67
59 struct FaceData { 68 struct FaceData {
60 CFX_ByteString name; 69 CFX_ByteString name;
61 uint32_t charset; 70 uint32_t charset;
62 }; 71 };
63 72
64 FX_BOOL m_bListLoaded; 73 FX_BOOL m_bListLoaded;
65 FXFT_Face m_MMFaces[MM_FACE_COUNT]; 74 FXFT_Face m_MMFaces[MM_FACE_COUNT];
66 CFX_ByteString m_LastFamily; 75 CFX_ByteString m_LastFamily;
67 std::vector<FaceData> m_FaceArray; 76 std::vector<FaceData> m_FaceArray;
68 std::unique_ptr<IFX_SystemFontInfo> m_pFontInfo; 77 std::unique_ptr<IFX_SystemFontInfo> m_pFontInfo;
69 FXFT_Face m_FoxitFaces[FOXIT_FACE_COUNT]; 78 FXFT_Face m_FoxitFaces[FOXIT_FACE_COUNT];
70 CFX_FontMgr* const m_pFontMgr; 79 CFX_FontMgr* const m_pFontMgr;
71 }; 80 };
72 81
73 #endif // CORE_FXGE_INCLUDE_CFX_FONTMAPPER_H_ 82 #endif // CORE_FXGE_INCLUDE_CFX_FONTMAPPER_H_
OLDNEW
« no previous file with comments | « core/fxge/ge/cfx_fontmapper.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698