| 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 _FWL_EDIT_LIGHT_H | 7 #ifndef _FWL_EDIT_LIGHT_H |
| 8 #define _FWL_EDIT_LIGHT_H | 8 #define _FWL_EDIT_LIGHT_H |
| 9 class CFWL_Widget; | 9 class CFWL_Widget; |
| 10 class CFWL_WidgetProperties; | 10 class CFWL_WidgetProperties; |
| 11 class CFWL_Edit; | 11 class CFWL_Edit; |
| 12 class CFWL_Edit : public CFWL_Widget | 12 class CFWL_Edit : public CFWL_Widget |
| 13 { | 13 { |
| 14 public: | 14 public: |
| 15 static CFWL_Edit* Create(); | 15 static CFWL_Edit* Create(); |
| 16 FWL_ERR Initialize(const CFWL_WidgetProperties *pProperties = NULL); | 16 FWL_ERR Initialize(const CFWL_WidgetProperties *pProperties = NULL); |
| 17 FWL_ERR SetText(const CFX_WideString &wsText); | 17 FWL_ERR SetText(const CFX_WideString &wsText); |
| 18 FX_INT32» GetTextLength() const; | 18 int32_t» GetTextLength() const; |
| 19 FWL_ERR» » GetText(CFX_WideString &wsText, FX_INT32 nStart = 0, FX_
INT32 nCount = -1) const; | 19 FWL_ERR» » GetText(CFX_WideString &wsText, int32_t nStart = 0, int3
2_t nCount = -1) const; |
| 20 FWL_ERR ClearText(); | 20 FWL_ERR ClearText(); |
| 21 FX_INT32» GetCaretPos() const; | 21 int32_t» GetCaretPos() const; |
| 22 FX_INT32» SetCaretPos(FX_INT32 nIndex, FX_BOOL bBefore = TRUE); | 22 int32_t» SetCaretPos(int32_t nIndex, FX_BOOL bBefore = TRUE); |
| 23 FWL_ERR» » AddSelRange(FX_INT32 nStart, FX_INT32 nCount = -1); | 23 FWL_ERR» » AddSelRange(int32_t nStart, int32_t nCount = -1); |
| 24 FX_INT32» CountSelRanges(); | 24 int32_t» CountSelRanges(); |
| 25 FX_INT32» GetSelRange(FX_INT32 nIndex, FX_INT32 &nStart); | 25 int32_t» GetSelRange(int32_t nIndex, int32_t &nStart); |
| 26 FWL_ERR ClearSelections(); | 26 FWL_ERR ClearSelections(); |
| 27 FX_INT32» GetLimit(); | 27 int32_t» GetLimit(); |
| 28 FWL_ERR» » SetLimit(FX_INT32 nLimit); | 28 FWL_ERR» » SetLimit(int32_t nLimit); |
| 29 FWL_ERR SetAliasChar(FX_WCHAR wAlias); | 29 FWL_ERR SetAliasChar(FX_WCHAR wAlias); |
| 30 FWL_ERR SetFormatString(const CFX_WideString &wsFormat); | 30 FWL_ERR SetFormatString(const CFX_WideString &wsFormat); |
| 31 FWL_ERR» » Insert(FX_INT32 nStart, FX_LPCWSTR lpText, FX_INT32 nLen
); | 31 FWL_ERR» » Insert(int32_t nStart, FX_LPCWSTR lpText, int32_t nLen); |
| 32 FWL_ERR DeleteSelections(); | 32 FWL_ERR DeleteSelections(); |
| 33 FWL_ERR» » DeleteRange(FX_INT32 nStart, FX_INT32 nCount = -1); | 33 FWL_ERR» » DeleteRange(int32_t nStart, int32_t nCount = -1); |
| 34 FWL_ERR ReplaceSelections(const CFX_WideStringC &wsReplace); | 34 FWL_ERR ReplaceSelections(const CFX_WideStringC &wsReplace); |
| 35 FWL_ERR» » Replace(FX_INT32 nStart, FX_INT32 nLen, const CFX_WideSt
ringC &wsReplace); | 35 FWL_ERR» » Replace(int32_t nStart, int32_t nLen, const CFX_WideStri
ngC &wsReplace); |
| 36 FWL_ERR» » DoClipboard(FX_INT32 iCmd); | 36 FWL_ERR» » DoClipboard(int32_t iCmd); |
| 37 FX_BOOL Redo(FX_BSTR bsRecord); | 37 FX_BOOL Redo(FX_BSTR bsRecord); |
| 38 FX_BOOL Undo(FX_BSTR bsRecord); | 38 FX_BOOL Undo(FX_BSTR bsRecord); |
| 39 FWL_ERR SetTabWidth(FX_FLOAT fTabWidth, FX_BOOL bEquidistant); | 39 FWL_ERR SetTabWidth(FX_FLOAT fTabWidth, FX_BOOL bEquidistant); |
| 40 FWL_ERR» » SetNumberRange(FX_INT32 iMin, FX_INT32 iMax); | 40 FWL_ERR» » SetNumberRange(int32_t iMin, int32_t iMax); |
| 41 FWL_ERR SetBackColor(FX_DWORD dwColor); | 41 FWL_ERR SetBackColor(FX_DWORD dwColor); |
| 42 FWL_ERR SetFont(const CFX_WideString &wsFont, FX_FLOAT fSize); | 42 FWL_ERR SetFont(const CFX_WideString &wsFont, FX_FLOAT fSize); |
| 43 FX_BOOL CanUndo(); | 43 FX_BOOL CanUndo(); |
| 44 FX_BOOL CanRedo(); | 44 FX_BOOL CanRedo(); |
| 45 FX_BOOL Undo(); | 45 FX_BOOL Undo(); |
| 46 FX_BOOL Redo(); | 46 FX_BOOL Redo(); |
| 47 FX_BOOL Copy(CFX_WideString &wsCopy); | 47 FX_BOOL Copy(CFX_WideString &wsCopy); |
| 48 FX_BOOL Cut(CFX_WideString &wsCut); | 48 FX_BOOL Cut(CFX_WideString &wsCut); |
| 49 FX_BOOL Paste(const CFX_WideString &wsPaste); | 49 FX_BOOL Paste(const CFX_WideString &wsPaste); |
| 50 FX_BOOL Delete(); | 50 FX_BOOL Delete(); |
| 51 void SetScrollOffset(FX_FLOAT fScrollOffset); | 51 void SetScrollOffset(FX_FLOAT fScrollOffset); |
| 52 FX_BOOL GetSuggestWords(CFX_PointF pointf, CFX_ByteStringArray &
sSuggest); | 52 FX_BOOL GetSuggestWords(CFX_PointF pointf, CFX_ByteStringArray &
sSuggest); |
| 53 FX_BOOL ReplaceSpellCheckWord(CFX_PointF pointf, FX_BSTR bsRepla
ce); | 53 FX_BOOL ReplaceSpellCheckWord(CFX_PointF pointf, FX_BSTR bsRepla
ce); |
| 54 CFWL_Edit(); | 54 CFWL_Edit(); |
| 55 virtual ~CFWL_Edit(); | 55 virtual ~CFWL_Edit(); |
| 56 }; | 56 }; |
| 57 #endif | 57 #endif |
| OLD | NEW |