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

Side by Side Diff: core/fpdfapi/font/cpdf_cidfont.h

Issue 2611413002: Remove CFX_ArrayTemplate from fpdfapi (Closed)
Patch Set: comment Created 3 years, 11 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/fpdfapi/edit/fpdf_edit_create.cpp ('k') | core/fpdfapi/font/cpdf_cidfont.cpp » ('j') | 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_FPDFAPI_FONT_CPDF_CIDFONT_H_ 7 #ifndef CORE_FPDFAPI_FONT_CPDF_CIDFONT_H_
8 #define CORE_FPDFAPI_FONT_CPDF_CIDFONT_H_ 8 #define CORE_FPDFAPI_FONT_CPDF_CIDFONT_H_
9 9
10 #include <memory> 10 #include <memory>
11 #include <vector>
11 12
12 #include "core/fpdfapi/font/cpdf_font.h" 13 #include "core/fpdfapi/font/cpdf_font.h"
13 #include "core/fxcrt/fx_string.h" 14 #include "core/fxcrt/fx_string.h"
14 #include "core/fxcrt/fx_system.h" 15 #include "core/fxcrt/fx_system.h"
15 16
16 enum CIDSet { 17 enum CIDSet {
17 CIDSET_UNKNOWN, 18 CIDSET_UNKNOWN,
18 CIDSET_GB1, 19 CIDSET_GB1,
19 CIDSET_CNS1, 20 CIDSET_CNS1,
20 CIDSET_JAPAN1, 21 CIDSET_JAPAN1,
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 const uint8_t* GetCIDTransform(uint16_t CID) const; 59 const uint8_t* GetCIDTransform(uint16_t CID) const;
59 short GetVertWidth(uint16_t CID) const; 60 short GetVertWidth(uint16_t CID) const;
60 void GetVertOrigin(uint16_t CID, short& vx, short& vy) const; 61 void GetVertOrigin(uint16_t CID, short& vx, short& vy) const;
61 int GetCharSize(uint32_t charcode) const; 62 int GetCharSize(uint32_t charcode) const;
62 63
63 protected: 64 protected:
64 void LoadGB2312(); 65 void LoadGB2312();
65 int GetGlyphIndex(uint32_t unicodeb, bool* pVertGlyph); 66 int GetGlyphIndex(uint32_t unicodeb, bool* pVertGlyph);
66 int GetVerticalGlyph(int index, bool* pVertGlyph); 67 int GetVerticalGlyph(int index, bool* pVertGlyph);
67 void LoadMetricsArray(CPDF_Array* pArray, 68 void LoadMetricsArray(CPDF_Array* pArray,
68 CFX_ArrayTemplate<uint32_t>& result, 69 std::vector<uint32_t>* result,
69 int nElements); 70 int nElements);
70 void LoadSubstFont(); 71 void LoadSubstFont();
71 FX_WCHAR GetUnicodeFromCharCode(uint32_t charcode) const; 72 FX_WCHAR GetUnicodeFromCharCode(uint32_t charcode) const;
72 73
73 CPDF_CMap* m_pCMap; 74 CPDF_CMap* m_pCMap;
74 std::unique_ptr<CPDF_CMap> m_pAllocatedCMap; 75 std::unique_ptr<CPDF_CMap> m_pAllocatedCMap;
75 CPDF_CID2UnicodeMap* m_pCID2UnicodeMap; 76 CPDF_CID2UnicodeMap* m_pCID2UnicodeMap;
76 CIDSet m_Charset; 77 CIDSet m_Charset;
77 bool m_bType1; 78 bool m_bType1;
78 bool m_bCIDIsGID; 79 bool m_bCIDIsGID;
79 uint16_t m_DefaultWidth; 80 uint16_t m_DefaultWidth;
80 std::unique_ptr<CPDF_StreamAcc> m_pStreamAcc; 81 std::unique_ptr<CPDF_StreamAcc> m_pStreamAcc;
81 bool m_bAnsiWidthsFixed; 82 bool m_bAnsiWidthsFixed;
82 FX_RECT m_CharBBox[256]; 83 FX_RECT m_CharBBox[256];
83 CFX_ArrayTemplate<uint32_t> m_WidthList; 84 std::vector<uint32_t> m_WidthList;
84 short m_DefaultVY; 85 short m_DefaultVY;
85 short m_DefaultW1; 86 short m_DefaultW1;
86 CFX_ArrayTemplate<uint32_t> m_VertMetrics; 87 std::vector<uint32_t> m_VertMetrics;
87 bool m_bAdobeCourierStd; 88 bool m_bAdobeCourierStd;
88 std::unique_ptr<CFX_CTTGSUBTable> m_pTTGSUBTable; 89 std::unique_ptr<CFX_CTTGSUBTable> m_pTTGSUBTable;
89 }; 90 };
90 91
91 #endif // CORE_FPDFAPI_FONT_CPDF_CIDFONT_H_ 92 #endif // CORE_FPDFAPI_FONT_CPDF_CIDFONT_H_
OLDNEW
« no previous file with comments | « core/fpdfapi/edit/fpdf_edit_create.cpp ('k') | core/fpdfapi/font/cpdf_cidfont.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698