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

Side by Side Diff: xfa/fee/fde_txtedtengine.h

Issue 1882213002: Cleanup various IFX_ text interfaces. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 8 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 | « xfa/fde/tto/fde_textout.cpp ('k') | xfa/fee/fde_txtedtengine.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 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 XFA_FEE_FDE_TXTEDTENGINE_H_ 7 #ifndef XFA_FEE_FDE_TXTEDTENGINE_H_
8 #define XFA_FEE_FDE_TXTEDTENGINE_H_ 8 #define XFA_FEE_FDE_TXTEDTENGINE_H_
9 9
10 #include "core/fxcrt/include/fx_string.h" 10 #include "core/fxcrt/include/fx_string.h"
11 #include "xfa/fee/ifde_txtedtbuf.h" 11 #include "xfa/fee/ifde_txtedtbuf.h"
12 #include "xfa/fee/ifde_txtedtengine.h" 12 #include "xfa/fee/ifde_txtedtengine.h"
13 #include "xfa/fgas/layout/fgas_textbreak.h"
13 14
14 class IFX_TxtBreak; 15 class CFX_TxtBreak;
15 class IFX_CharIter; 16 class IFX_CharIter;
16 class CFDE_TxtEdtParag; 17 class CFDE_TxtEdtParag;
17 class CFDE_TxtEdtDoRecord_Insert; 18 class CFDE_TxtEdtDoRecord_Insert;
18 class CFDE_TxtEdtDoRecord_DeleteRange; 19 class CFDE_TxtEdtDoRecord_DeleteRange;
19 20
20 class IFDE_TxtEdtDoRecord { 21 class IFDE_TxtEdtDoRecord {
21 public: 22 public:
22 static IFDE_TxtEdtDoRecord* Create(const CFX_ByteStringC& bsDoRecord); 23 static IFDE_TxtEdtDoRecord* Create(const CFX_ByteStringC& bsDoRecord);
23 virtual ~IFDE_TxtEdtDoRecord() {} 24 virtual ~IFDE_TxtEdtDoRecord() {}
24 virtual void Release() = 0; 25 virtual void Release() = 0;
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 virtual int32_t StartLayout(); 99 virtual int32_t StartLayout();
99 virtual int32_t DoLayout(IFX_Pause* pPause); 100 virtual int32_t DoLayout(IFX_Pause* pPause);
100 virtual void EndLayout(); 101 virtual void EndLayout();
101 102
102 virtual FX_BOOL Optimize(IFX_Pause* pPause = NULL); 103 virtual FX_BOOL Optimize(IFX_Pause* pPause = NULL);
103 virtual int32_t CountParags() const; 104 virtual int32_t CountParags() const;
104 virtual IFDE_TxtEdtParag* GetParag(int32_t nParagIndex) const; 105 virtual IFDE_TxtEdtParag* GetParag(int32_t nParagIndex) const;
105 virtual IFX_CharIter* CreateCharIter(); 106 virtual IFX_CharIter* CreateCharIter();
106 IFDE_TxtEdtBuf* GetTextBuf() const; 107 IFDE_TxtEdtBuf* GetTextBuf() const;
107 int32_t GetTextBufLength() const; 108 int32_t GetTextBufLength() const;
108 IFX_TxtBreak* GetTextBreak() const; 109 CFX_TxtBreak* GetTextBreak() const;
109 int32_t GetLineCount() const; 110 int32_t GetLineCount() const;
110 int32_t GetPageLineCount() const; 111 int32_t GetPageLineCount() const;
111 112
112 int32_t Line2Parag(int32_t nStartParag, 113 int32_t Line2Parag(int32_t nStartParag,
113 int32_t nStartLineofParag, 114 int32_t nStartLineofParag,
114 int32_t nLineIndex, 115 int32_t nLineIndex,
115 int32_t& nStartLine) const; 116 int32_t& nStartLine) const;
116 FX_WCHAR GetAliasChar() const { return m_wcAliasChar; } 117 FX_WCHAR GetAliasChar() const { return m_wcAliasChar; }
117 118
118 protected: 119 protected:
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 void GetCaretRect(CFX_RectF& rtCaret, 167 void GetCaretRect(CFX_RectF& rtCaret,
167 int32_t nPageIndex, 168 int32_t nPageIndex,
168 int32_t nCaret, 169 int32_t nCaret,
169 FX_BOOL bBefore = TRUE); 170 FX_BOOL bBefore = TRUE);
170 void UpdateCaretIndex(const CFX_PointF& ptCaret); 171 void UpdateCaretIndex(const CFX_PointF& ptCaret);
171 172
172 FX_BOOL IsSelect(); 173 FX_BOOL IsSelect();
173 void DeleteSelect(); 174 void DeleteSelect();
174 175
175 IFDE_TxtEdtBuf* m_pTxtBuf; 176 IFDE_TxtEdtBuf* m_pTxtBuf;
176 IFX_TxtBreak* m_pTextBreak; 177 CFX_TxtBreak* m_pTextBreak;
177 FDE_TXTEDTPARAMS m_Param; 178 FDE_TXTEDTPARAMS m_Param;
178 CFX_ArrayTemplate<IFDE_TxtEdtPage*> m_PagePtrArray; 179 CFX_ArrayTemplate<IFDE_TxtEdtPage*> m_PagePtrArray;
179 CFX_ArrayTemplate<CFDE_TxtEdtParag*> m_ParagPtrArray; 180 CFX_ArrayTemplate<CFDE_TxtEdtParag*> m_ParagPtrArray;
180 CFX_ArrayTemplate<FDE_LPTXTEDTSELRANGE> m_SelRangePtrArr; 181 CFX_ArrayTemplate<FDE_LPTXTEDTSELRANGE> m_SelRangePtrArr;
181 int32_t m_nPageLineCount; 182 int32_t m_nPageLineCount;
182 int32_t m_nLineCount; 183 int32_t m_nLineCount;
183 int32_t m_nAnchorPos; 184 int32_t m_nAnchorPos;
184 int32_t m_nLayoutPos; 185 int32_t m_nLayoutPos;
185 FX_FLOAT m_fCaretPosReserve; 186 FX_FLOAT m_fCaretPosReserve;
186 int32_t m_nCaret; 187 int32_t m_nCaret;
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
238 239
239 private: 240 private:
240 CFDE_TxtEdtEngine* m_pEngine; 241 CFDE_TxtEdtEngine* m_pEngine;
241 FX_BOOL m_bSel; 242 FX_BOOL m_bSel;
242 int32_t m_nIndex; 243 int32_t m_nIndex;
243 int32_t m_nCaret; 244 int32_t m_nCaret;
244 CFX_WideString m_wsRange; 245 CFX_WideString m_wsRange;
245 }; 246 };
246 247
247 #endif // XFA_FEE_FDE_TXTEDTENGINE_H_ 248 #endif // XFA_FEE_FDE_TXTEDTENGINE_H_
OLDNEW
« no previous file with comments | « xfa/fde/tto/fde_textout.cpp ('k') | xfa/fee/fde_txtedtengine.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698