| 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_FXCRT_INCLUDE_FX_STRING_H_ | 7 #ifndef CORE_FXCRT_INCLUDE_FX_STRING_H_ |
| 8 #define CORE_FXCRT_INCLUDE_FX_STRING_H_ | 8 #define CORE_FXCRT_INCLUDE_FX_STRING_H_ |
| 9 | 9 |
| 10 #include <stdint.h> // For intptr_t. | 10 #include <stdint.h> // For intptr_t. |
| (...skipping 490 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 501 | 501 |
| 502 CFX_WideString(const CFX_WideStringC& str); | 502 CFX_WideString(const CFX_WideStringC& str); |
| 503 CFX_WideString(const CFX_WideStringC& str1, const CFX_WideStringC& str2); | 503 CFX_WideString(const CFX_WideStringC& str1, const CFX_WideStringC& str2); |
| 504 | 504 |
| 505 ~CFX_WideString(); | 505 ~CFX_WideString(); |
| 506 | 506 |
| 507 static CFX_WideString FromLocal(const CFX_ByteString& str); | 507 static CFX_WideString FromLocal(const CFX_ByteString& str); |
| 508 static CFX_WideString FromCodePage(const CFX_ByteString& str, | 508 static CFX_WideString FromCodePage(const CFX_ByteString& str, |
| 509 uint16_t codepage); | 509 uint16_t codepage); |
| 510 | 510 |
| 511 static CFX_WideString FromUTF8(const char* str, FX_STRSIZE len); | 511 static CFX_WideString FromUTF8(const CFX_ByteStringC& str); |
| 512 static CFX_WideString FromUTF16LE(const unsigned short* str, FX_STRSIZE len); | 512 static CFX_WideString FromUTF16LE(const unsigned short* str, FX_STRSIZE len); |
| 513 | 513 |
| 514 static FX_STRSIZE WStringLength(const unsigned short* str); | 514 static FX_STRSIZE WStringLength(const unsigned short* str); |
| 515 | 515 |
| 516 // Explicit conversion to C-style wide string. | 516 // Explicit conversion to C-style wide string. |
| 517 // Note: |this| must outlive the use of the result. | 517 // Note: |this| must outlive the use of the result. |
| 518 const FX_WCHAR* c_str() const { return m_pData ? m_pData->m_String : L""; } | 518 const FX_WCHAR* c_str() const { return m_pData ? m_pData->m_String : L""; } |
| 519 | 519 |
| 520 // Implicit conversion to C-style wide string -- deprecated. | 520 // Implicit conversion to C-style wide string -- deprecated. |
| 521 // Note: |this| must outlive the use of the result. | 521 // Note: |this| must outlive the use of the result. |
| (...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 722 } | 722 } |
| 723 | 723 |
| 724 FX_FLOAT FX_atof(const CFX_ByteStringC& str); | 724 FX_FLOAT FX_atof(const CFX_ByteStringC& str); |
| 725 inline FX_FLOAT FX_atof(const CFX_WideStringC& wsStr) { | 725 inline FX_FLOAT FX_atof(const CFX_WideStringC& wsStr) { |
| 726 return FX_atof(FX_UTF8Encode(wsStr.raw_str(), wsStr.GetLength()).c_str()); | 726 return FX_atof(FX_UTF8Encode(wsStr.raw_str(), wsStr.GetLength()).c_str()); |
| 727 } | 727 } |
| 728 void FX_atonum(const CFX_ByteStringC& str, FX_BOOL& bInteger, void* pData); | 728 void FX_atonum(const CFX_ByteStringC& str, FX_BOOL& bInteger, void* pData); |
| 729 FX_STRSIZE FX_ftoa(FX_FLOAT f, FX_CHAR* buf); | 729 FX_STRSIZE FX_ftoa(FX_FLOAT f, FX_CHAR* buf); |
| 730 | 730 |
| 731 #endif // CORE_FXCRT_INCLUDE_FX_STRING_H_ | 731 #endif // CORE_FXCRT_INCLUDE_FX_STRING_H_ |
| OLD | NEW |