| 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 _FX_STRING_H_ | 7 #ifndef _FX_STRING_H_ |
| 8 #define _FX_STRING_H_ | 8 #define _FX_STRING_H_ |
| 9 class CFX_ByteStringC; | 9 class CFX_ByteStringC; |
| 10 class CFX_ByteString; | 10 class CFX_ByteString; |
| (...skipping 616 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 627 CFX_WideString(FX_WCHAR ch); | 627 CFX_WideString(FX_WCHAR ch); |
| 628 | 628 |
| 629 CFX_WideString(const CFX_WideStringC& str); | 629 CFX_WideString(const CFX_WideStringC& str); |
| 630 | 630 |
| 631 CFX_WideString(const CFX_WideStringC& str1, const CFX_WideStringC& str2); | 631 CFX_WideString(const CFX_WideStringC& str1, const CFX_WideStringC& str2); |
| 632 | 632 |
| 633 ~CFX_WideString(); | 633 ~CFX_WideString(); |
| 634 | 634 |
| 635 static CFX_WideString FromLocal(const char* str, FX_STRSIZE len = -1); | 635 static CFX_WideString FromLocal(const char* str, FX_STRSIZE len = -1); |
| 636 | 636 |
| 637 static CFX_WideString» FromUTF8(const char* str, FX_STRSIZE len = -1); | 637 static CFX_WideString» FromUTF8(const char* str, FX_STRSIZE len); |
| 638 | 638 |
| 639 static CFX_WideString» FromUTF16LE(const unsigned short* str, FX_STRSIZ
E len = -1); | 639 static CFX_WideString» FromUTF16LE(const unsigned short* str, FX_STRSIZ
E len); |
| 640 | 640 |
| 641 operator FX_LPCWSTR() const | 641 operator FX_LPCWSTR() const |
| 642 { | 642 { |
| 643 return m_pData ? m_pData->m_String : (FX_WCHAR*)L""; | 643 return m_pData ? m_pData->m_String : (FX_WCHAR*)L""; |
| 644 } | 644 } |
| 645 | 645 |
| 646 void Empty(); | 646 void Empty(); |
| 647 | 647 |
| 648 | 648 |
| 649 FX_BOOL IsEmpty() const | 649 FX_BOOL IsEmpty() const |
| (...skipping 185 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 835 CFX_ByteString FX_UTF8Encode(FX_LPCWSTR pwsStr, FX_STRSIZE len); | 835 CFX_ByteString FX_UTF8Encode(FX_LPCWSTR pwsStr, FX_STRSIZE len); |
| 836 inline CFX_ByteString FX_UTF8Encode(FX_WSTR wsStr) | 836 inline CFX_ByteString FX_UTF8Encode(FX_WSTR wsStr) |
| 837 { | 837 { |
| 838 return FX_UTF8Encode(wsStr.GetPtr(), wsStr.GetLength()); | 838 return FX_UTF8Encode(wsStr.GetPtr(), wsStr.GetLength()); |
| 839 } | 839 } |
| 840 inline CFX_ByteString FX_UTF8Encode(const CFX_WideString &wsStr) | 840 inline CFX_ByteString FX_UTF8Encode(const CFX_WideString &wsStr) |
| 841 { | 841 { |
| 842 return FX_UTF8Encode((FX_LPCWSTR)wsStr, wsStr.GetLength()); | 842 return FX_UTF8Encode((FX_LPCWSTR)wsStr, wsStr.GetLength()); |
| 843 } | 843 } |
| 844 #endif | 844 #endif |
| OLD | NEW |