OLD | NEW |
1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 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 _TEXT_INT_H_ | 7 #ifndef _TEXT_INT_H_ |
8 #define _TEXT_INT_H_ | 8 #define _TEXT_INT_H_ |
9 | 9 |
10 struct _CFX_UniqueKeyGen { | 10 struct _CFX_UniqueKeyGen { |
11 void Generate(int count, ...); | 11 void Generate(int count, ...); |
12 FX_CHAR m_Key[128]; | 12 FX_CHAR m_Key[128]; |
13 int m_KeyLen; | 13 int m_KeyLen; |
14 }; | 14 }; |
15 class CFX_SizeGlyphCache : public CFX_Object | 15 class CFX_SizeGlyphCache |
16 { | 16 { |
17 public: | 17 public: |
18 CFX_SizeGlyphCache() | 18 CFX_SizeGlyphCache() |
19 { | 19 { |
20 m_GlyphMap.InitHashTable(253); | 20 m_GlyphMap.InitHashTable(253); |
21 } | 21 } |
22 ~CFX_SizeGlyphCache(); | 22 ~CFX_SizeGlyphCache(); |
23 CFX_MapPtrToPtr m_GlyphMap; | 23 CFX_MapPtrToPtr m_GlyphMap; |
24 }; | 24 }; |
25 class CTTFontDesc : public CFX_Object | 25 class CTTFontDesc |
26 { | 26 { |
27 public: | 27 public: |
28 CTTFontDesc() | 28 CTTFontDesc() |
29 { | 29 { |
30 m_Type = 0; | 30 m_Type = 0; |
31 m_pFontData = NULL; | 31 m_pFontData = NULL; |
32 m_RefCount = 0; | 32 m_RefCount = 0; |
33 } | 33 } |
34 ~CTTFontDesc(); | 34 ~CTTFontDesc(); |
35 FX_BOOL ReleaseFace(FXFT_Face face); | 35 FX_BOOL ReleaseFace(FXFT_Face face); |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
67 { | 67 { |
68 return TRUE; | 68 return TRUE; |
69 } | 69 } |
70 }; | 70 }; |
71 #define CHARSET_FLAG_ANSI 1 | 71 #define CHARSET_FLAG_ANSI 1 |
72 #define CHARSET_FLAG_SYMBOL 2 | 72 #define CHARSET_FLAG_SYMBOL 2 |
73 #define CHARSET_FLAG_SHIFTJIS 4 | 73 #define CHARSET_FLAG_SHIFTJIS 4 |
74 #define CHARSET_FLAG_BIG5 8 | 74 #define CHARSET_FLAG_BIG5 8 |
75 #define CHARSET_FLAG_GB 16 | 75 #define CHARSET_FLAG_GB 16 |
76 #define CHARSET_FLAG_KOREAN 32 | 76 #define CHARSET_FLAG_KOREAN 32 |
77 class CFontFaceInfo : public CFX_Object | 77 class CFontFaceInfo |
78 { | 78 { |
79 public: | 79 public: |
80 CFX_ByteString m_FilePath; | 80 CFX_ByteString m_FilePath; |
81 CFX_ByteString m_FaceName; | 81 CFX_ByteString m_FaceName; |
82 FX_DWORD m_Styles; | 82 FX_DWORD m_Styles; |
83 FX_DWORD m_Charsets; | 83 FX_DWORD m_Charsets; |
84 FX_DWORD m_FontOffset; | 84 FX_DWORD m_FontOffset; |
85 FX_DWORD m_FileSize; | 85 FX_DWORD m_FileSize; |
86 CFX_ByteString m_FontTables; | 86 CFX_ByteString m_FontTables; |
87 }; | 87 }; |
88 class CFontFileFaceInfo : public CFX_Object | 88 class CFontFileFaceInfo |
89 { | 89 { |
90 public: | 90 public: |
91 CFontFileFaceInfo(); | 91 CFontFileFaceInfo(); |
92 ~CFontFileFaceInfo(); | 92 ~CFontFileFaceInfo(); |
93 IFX_FileStream* m_pFile; | 93 IFX_FileStream* m_pFile; |
94 FXFT_Face m_Face; | 94 FXFT_Face m_Face; |
95 CFX_ByteString m_FaceName; | 95 CFX_ByteString m_FaceName; |
96 FX_DWORD m_Charsets; | 96 FX_DWORD m_Charsets; |
97 FX_DWORD m_FileSize; | 97 FX_DWORD m_FileSize; |
98 FX_DWORD m_FontOffset; | 98 FX_DWORD m_FontOffset; |
(...skipping 16 matching lines...) Expand all Loading... |
115 virtual FX_BOOL IsUnicodeCompatible() const; | 115 virtual FX_BOOL IsUnicodeCompatible() const; |
116 virtual FX_DWORD GlyphFromCharCodeEx(FX_DWORD charcode, int encod
ing = ENCODING_UNICODE) | 116 virtual FX_DWORD GlyphFromCharCodeEx(FX_DWORD charcode, int encod
ing = ENCODING_UNICODE) |
117 { | 117 { |
118 return GlyphFromCharCode(charcode); | 118 return GlyphFromCharCode(charcode); |
119 } | 119 } |
120 private: | 120 private: |
121 CFX_Font* m_pFont; | 121 CFX_Font* m_pFont; |
122 FX_DWORD m_nEncodingID; | 122 FX_DWORD m_nEncodingID; |
123 }; | 123 }; |
124 #endif // _TEXT_INT_H_ | 124 #endif // _TEXT_INT_H_ |
OLD | NEW |