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 CORE_FPDFTEXT_FPDF_TEXT_INT_H_ | 7 #ifndef CORE_FPDFTEXT_FPDF_TEXT_INT_H_ |
8 #define CORE_FPDFTEXT_FPDF_TEXT_INT_H_ | 8 #define CORE_FPDFTEXT_FPDF_TEXT_INT_H_ |
9 | 9 |
10 #include <deque> | 10 #include <deque> |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
133 void AddCharInfoByRLDirection(FX_WCHAR wChar, PAGECHAR_INFO info); | 133 void AddCharInfoByRLDirection(FX_WCHAR wChar, PAGECHAR_INFO info); |
134 int32_t GetTextObjectWritingMode(const CPDF_TextObject* pTextObj); | 134 int32_t GetTextObjectWritingMode(const CPDF_TextObject* pTextObj); |
135 int32_t FindTextlineFlowDirection(); | 135 int32_t FindTextlineFlowDirection(); |
136 | 136 |
137 void SwapTempTextBuf(int32_t iCharListStartAppend, int32_t iBufStartAppend); | 137 void SwapTempTextBuf(int32_t iCharListStartAppend, int32_t iBufStartAppend); |
138 FX_BOOL IsRightToLeft(const CPDF_TextObject* pTextObj, | 138 FX_BOOL IsRightToLeft(const CPDF_TextObject* pTextObj, |
139 const CPDF_Font* pFont, | 139 const CPDF_Font* pFont, |
140 int nItems) const; | 140 int nItems) const; |
141 | 141 |
142 const CPDF_Page* const m_pPage; | 142 const CPDF_Page* const m_pPage; |
143 std::vector<FX_WORD> m_CharIndex; | 143 std::vector<uint16_t> m_CharIndex; |
144 std::deque<PAGECHAR_INFO> m_CharList; | 144 std::deque<PAGECHAR_INFO> m_CharList; |
145 std::deque<PAGECHAR_INFO> m_TempCharList; | 145 std::deque<PAGECHAR_INFO> m_TempCharList; |
146 CFX_WideTextBuf m_TextBuf; | 146 CFX_WideTextBuf m_TextBuf; |
147 CFX_WideTextBuf m_TempTextBuf; | 147 CFX_WideTextBuf m_TempTextBuf; |
148 const int m_parserflag; | 148 const int m_parserflag; |
149 CPDF_TextObject* m_pPreTextObj; | 149 CPDF_TextObject* m_pPreTextObj; |
150 CFX_Matrix m_perMatrix; | 150 CFX_Matrix m_perMatrix; |
151 bool m_bIsParsed; | 151 bool m_bIsParsed; |
152 CFX_Matrix m_DisplayMatrix; | 152 CFX_Matrix m_DisplayMatrix; |
153 CFX_ArrayTemplate<FPDF_SEGMENT> m_Segments; | 153 CFX_ArrayTemplate<FPDF_SEGMENT> m_Segments; |
(...skipping 28 matching lines...) Expand all Loading... |
182 int iSubString, | 182 int iSubString, |
183 FX_WCHAR chSep); | 183 FX_WCHAR chSep); |
184 CFX_WideString MakeReverse(const CFX_WideString& str); | 184 CFX_WideString MakeReverse(const CFX_WideString& str); |
185 int ReverseFind(const CFX_WideString& csPageText, | 185 int ReverseFind(const CFX_WideString& csPageText, |
186 const CFX_WideString& csWord, | 186 const CFX_WideString& csWord, |
187 int nStartPos, | 187 int nStartPos, |
188 int& WordLength); | 188 int& WordLength); |
189 int GetCharIndex(int index) const; | 189 int GetCharIndex(int index) const; |
190 | 190 |
191 private: | 191 private: |
192 std::vector<FX_WORD> m_CharIndex; | 192 std::vector<uint16_t> m_CharIndex; |
193 const IPDF_TextPage* m_pTextPage; | 193 const IPDF_TextPage* m_pTextPage; |
194 CFX_WideString m_strText; | 194 CFX_WideString m_strText; |
195 CFX_WideString m_findWhat; | 195 CFX_WideString m_findWhat; |
196 int m_flags; | 196 int m_flags; |
197 std::vector<CFX_WideString> m_csFindWhatArray; | 197 std::vector<CFX_WideString> m_csFindWhatArray; |
198 int m_findNextStart; | 198 int m_findNextStart; |
199 int m_findPreStart; | 199 int m_findPreStart; |
200 FX_BOOL m_bMatchCase; | 200 FX_BOOL m_bMatchCase; |
201 FX_BOOL m_bMatchWholeWord; | 201 FX_BOOL m_bMatchWholeWord; |
202 int m_resStart; | 202 int m_resStart; |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
238 void AppendToLinkList(int start, int count, const CFX_WideString& strUrl); | 238 void AppendToLinkList(int start, int count, const CFX_WideString& strUrl); |
239 | 239 |
240 private: | 240 private: |
241 LINK_InfoArray m_LinkList; | 241 LINK_InfoArray m_LinkList; |
242 const CPDF_TextPage* m_pTextPage; | 242 const CPDF_TextPage* m_pTextPage; |
243 CFX_WideString m_strPageText; | 243 CFX_WideString m_strPageText; |
244 bool m_bIsParsed; | 244 bool m_bIsParsed; |
245 }; | 245 }; |
246 | 246 |
247 #endif // CORE_FPDFTEXT_FPDF_TEXT_INT_H_ | 247 #endif // CORE_FPDFTEXT_FPDF_TEXT_INT_H_ |
OLD | NEW |