| 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 XFA_FWL_CORE_CFWL_EDIT_H_ | 7 #ifndef XFA_FWL_CORE_CFWL_EDIT_H_ |
| 8 #define XFA_FWL_CORE_CFWL_EDIT_H_ | 8 #define XFA_FWL_CORE_CFWL_EDIT_H_ |
| 9 | 9 |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 | 22 |
| 23 void Initialize(); | 23 void Initialize(); |
| 24 | 24 |
| 25 FWL_Error SetText(const CFX_WideString& wsText); | 25 FWL_Error SetText(const CFX_WideString& wsText); |
| 26 int32_t GetTextLength() const; | 26 int32_t GetTextLength() const; |
| 27 FWL_Error GetText(CFX_WideString& wsText, | 27 FWL_Error GetText(CFX_WideString& wsText, |
| 28 int32_t nStart = 0, | 28 int32_t nStart = 0, |
| 29 int32_t nCount = -1) const; | 29 int32_t nCount = -1) const; |
| 30 FWL_Error ClearText(); | 30 FWL_Error ClearText(); |
| 31 int32_t GetCaretPos() const; | 31 int32_t GetCaretPos() const; |
| 32 int32_t SetCaretPos(int32_t nIndex, FX_BOOL bBefore = TRUE); | 32 int32_t SetCaretPos(int32_t nIndex, bool bBefore = true); |
| 33 int32_t AddSelRange(int32_t nStart, int32_t nCount = -1); | 33 int32_t AddSelRange(int32_t nStart, int32_t nCount = -1); |
| 34 int32_t CountSelRanges(); | 34 int32_t CountSelRanges(); |
| 35 int32_t GetSelRange(int32_t nIndex, int32_t& nStart); | 35 int32_t GetSelRange(int32_t nIndex, int32_t& nStart); |
| 36 FWL_Error ClearSelections(); | 36 FWL_Error ClearSelections(); |
| 37 int32_t GetLimit(); | 37 int32_t GetLimit(); |
| 38 FWL_Error SetLimit(int32_t nLimit); | 38 FWL_Error SetLimit(int32_t nLimit); |
| 39 FWL_Error SetAliasChar(FX_WCHAR wAlias); | 39 FWL_Error SetAliasChar(FX_WCHAR wAlias); |
| 40 FWL_Error SetFormatString(const CFX_WideString& wsFormat); | 40 FWL_Error SetFormatString(const CFX_WideString& wsFormat); |
| 41 FWL_Error Insert(int32_t nStart, const FX_WCHAR* lpText, int32_t nLen); | 41 FWL_Error Insert(int32_t nStart, const FX_WCHAR* lpText, int32_t nLen); |
| 42 FWL_Error DeleteSelections(); | 42 FWL_Error DeleteSelections(); |
| 43 FWL_Error DeleteRange(int32_t nStart, int32_t nCount = -1); | 43 FWL_Error DeleteRange(int32_t nStart, int32_t nCount = -1); |
| 44 FWL_Error Replace(int32_t nStart, | 44 FWL_Error Replace(int32_t nStart, |
| 45 int32_t nLen, | 45 int32_t nLen, |
| 46 const CFX_WideStringC& wsReplace); | 46 const CFX_WideStringC& wsReplace); |
| 47 FWL_Error DoClipboard(int32_t iCmd); | 47 FWL_Error DoClipboard(int32_t iCmd); |
| 48 FX_BOOL Redo(const IFDE_TxtEdtDoRecord* pRecord); | 48 bool Redo(const IFDE_TxtEdtDoRecord* pRecord); |
| 49 FX_BOOL Undo(const IFDE_TxtEdtDoRecord* pRecord); | 49 bool Undo(const IFDE_TxtEdtDoRecord* pRecord); |
| 50 FWL_Error SetTabWidth(FX_FLOAT fTabWidth, FX_BOOL bEquidistant); | 50 FWL_Error SetTabWidth(FX_FLOAT fTabWidth, bool bEquidistant); |
| 51 FWL_Error SetNumberRange(int32_t iMin, int32_t iMax); | 51 FWL_Error SetNumberRange(int32_t iMin, int32_t iMax); |
| 52 FWL_Error SetBackColor(uint32_t dwColor); | 52 FWL_Error SetBackColor(uint32_t dwColor); |
| 53 FWL_Error SetFont(const CFX_WideString& wsFont, FX_FLOAT fSize); | 53 FWL_Error SetFont(const CFX_WideString& wsFont, FX_FLOAT fSize); |
| 54 FX_BOOL CanUndo(); | 54 bool CanUndo(); |
| 55 FX_BOOL CanRedo(); | 55 bool CanRedo(); |
| 56 FX_BOOL Undo(); | 56 bool Undo(); |
| 57 FX_BOOL Redo(); | 57 bool Redo(); |
| 58 FX_BOOL Copy(CFX_WideString& wsCopy); | 58 bool Copy(CFX_WideString& wsCopy); |
| 59 FX_BOOL Cut(CFX_WideString& wsCut); | 59 bool Cut(CFX_WideString& wsCut); |
| 60 FX_BOOL Paste(const CFX_WideString& wsPaste); | 60 bool Paste(const CFX_WideString& wsPaste); |
| 61 FX_BOOL Delete(); | 61 bool Delete(); |
| 62 void SetScrollOffset(FX_FLOAT fScrollOffset); | 62 void SetScrollOffset(FX_FLOAT fScrollOffset); |
| 63 FX_BOOL GetSuggestWords(CFX_PointF pointf, | 63 bool GetSuggestWords(CFX_PointF pointf, |
| 64 std::vector<CFX_ByteString>& sSuggest); | 64 std::vector<CFX_ByteString>& sSuggest); |
| 65 FX_BOOL ReplaceSpellCheckWord(CFX_PointF pointf, | 65 bool ReplaceSpellCheckWord(CFX_PointF pointf, |
| 66 const CFX_ByteStringC& bsReplace); | 66 const CFX_ByteStringC& bsReplace); |
| 67 }; | 67 }; |
| 68 | 68 |
| 69 #endif // XFA_FWL_CORE_CFWL_EDIT_H_ | 69 #endif // XFA_FWL_CORE_CFWL_EDIT_H_ |
| OLD | NEW |