Lines Matching refs:wchar_t

39   native support for wchar_t:

40 _MSC_VER == 1600 : /Zc:wchar_t is not supported
42 ? _MSC_VER == 1400 (VS2005) : wchar_t <- unsigned short
43 /Zc:wchar_t : wchar_t <- __wchar_t, _WCHAR_T_DEFINED and _NATIVE_WCHAR_T_DEFINED
45 /Zc:wchar_t[-]
46 /Zc:wchar_t is on by default
56 inline bool IsPathSepar(wchar_t c) { return IS_PATH_SEPAR(c); }
90 inline unsigned MyStringLen(const wchar_t *s)
97 inline void MyStringCopy(wchar_t *dest, const wchar_t *src)
102 inline void MyStringCat(wchar_t *dest, const wchar_t *src)
111 inline wchar_t *MyWcpCpy(wchar_t *dest, const wchar_t *src)
115 const wchar_t c = *src;
126 int FindCharPosInString(const wchar_t *s, wchar_t c) throw();
147 inline wchar_t MyCharUpper_Ascii(wchar_t c)
150 return (wchar_t)(c - 0x20);
162 inline wchar_t MyCharLower_Ascii(wchar_t c)
165 return (wchar_t)(c + 0x20);
169 wchar_t MyCharUpper_WIN(wchar_t c) throw();
171 inline wchar_t MyCharUpper(wchar_t c) throw()
174 if (c <= 'z') return (wchar_t)(c - 0x20);
178 return (wchar_t)(unsigned)(UINT_PTR)CharUpperW((LPWSTR)(UINT_PTR)(unsigned)c);
180 return (wchar_t)MyCharUpper_WIN(c);
183 return (wchar_t)towupper((wint_t)c);
188 wchar_t MyCharLower_WIN(wchar_t c) throw();
190 inline wchar_t MyCharLower(wchar_t c) throw()
193 if (c <= 'Z') return (wchar_t)(c + 0x20);
197 return (wchar_t)(unsigned)(UINT_PTR)CharLowerW((LPWSTR)(UINT_PTR)(unsigned)c);
199 return (wchar_t)MyCharLower_WIN(c);
202 return (wchar_t)tolower(c);
211 // void MyStringUpper_Ascii(wchar_t *s) throw();
213 void MyStringLower_Ascii(wchar_t *s) throw();
214 // wchar_t *MyStringUpper(wchar_t *s) STRING_UNICODE_THROW;
215 // wchar_t *MyStringLower(wchar_t *s) STRING_UNICODE_THROW;
217 bool StringsAreEqualNoCase(const wchar_t *s1, const wchar_t *s2) throw();
220 bool IsString1PrefixedByString2(const wchar_t *s1, const wchar_t *s2) throw();
221 bool IsString1PrefixedByString2(const wchar_t *s1, const char *s2) throw();
223 bool IsString1PrefixedByString2_NoCase_Ascii(const wchar_t *u, const char *a) throw();
224 bool IsString1PrefixedByString2_NoCase(const wchar_t *s1, const wchar_t *s2) throw();
227 int MyStringCompareNoCase(const wchar_t *s1, const wchar_t *s2) throw();
228 // int MyStringCompareNoCase_N(const wchar_t *s1, const wchar_t *s2, unsigned num) throw();
233 bool StringsAreEqual_Ascii(const wchar_t *u, const char *a) throw();
235 bool StringsAreEqualNoCase_Ascii(const wchar_t *s1, const char *s2) throw();
236 bool StringsAreEqualNoCase_Ascii(const wchar_t *s1, const wchar_t *s2) throw();
302 FORBID_STRING_OPS_AString(wchar_t)
373 void SetFromWStr_if_Ascii(const wchar_t *s);
551 wchar_t *_chars;
557 memmove(_chars + dest, _chars + src, (size_t)(_len - src + 1) * sizeof(wchar_t));
568 UString(unsigned num, const wchar_t *s); // for Mid
570 UString(const UString &s, wchar_t c); // it's for String + char
571 UString(const wchar_t *s1, unsigned num1, const wchar_t *s2, unsigned num2);
573 friend UString operator+(const UString &s, wchar_t c) { return UString(s, c); }
574 // friend UString operator+(wchar_t c, const UString &s); // is not supported
577 friend UString operator+(const UString &s1, const wchar_t *s2);
578 friend UString operator+(const wchar_t *s1, const UString &s2);
605 explicit UString(wchar_t c);
609 UString(const wchar_t *s);
617 operator const wchar_t *() const { return _chars; }
618 wchar_t *Ptr_non_const() const { return _chars; }
619 const wchar_t *Ptr() const { return _chars; }
620 const wchar_t *Ptr(int pos) const { return _chars + (unsigned)pos; }
621 const wchar_t *Ptr(unsigned pos) const { return _chars + pos; }
622 const wchar_t *RightPtr(unsigned num) const { return _chars + _len - num; }
623 wchar_t Back() const { return _chars[(size_t)_len - 1]; }
625 void ReplaceOneCharAtPos(unsigned pos, wchar_t c) { _chars[pos] = c; }
627 wchar_t *GetBuf() { return _chars; }
630 wchar_t *GetBuf_GetMaxAvail(unsigned &availBufLen)
637 wchar_t *GetBuf(unsigned minLen)
643 wchar_t *GetBuf_SetEnd(unsigned minLen)
647 wchar_t *chars = _chars;
657 wchar_t *chars = _chars;
662 UString &operator=(wchar_t c);
663 UString &operator=(char c) { return (*this)=((wchar_t)(unsigned char)c); }
664 UString &operator=(const wchar_t *s);
666 void SetFrom(const wchar_t *s, unsigned len); // no check
671 UString &operator+=(wchar_t c)
676 wchar_t *chars = _chars;
683 UString &operator+=(char c) { return (*this)+=((wchar_t)(unsigned char)c); }
691 UString &operator+=(const wchar_t *s);
709 bool IsEqualTo_NoCase(const wchar_t *s) const { return StringsAreEqualNoCase(_chars, s); }
711 int Compare(const wchar_t *s) const { return wcscmp(_chars, s); }
713 // int CompareNoCase(const wchar_t *s) const { return MyStringCompareNoCase(_chars, s); }
715 bool IsPrefixedBy(const wchar_t *s) const { return IsString1PrefixedByString2(_chars, s); }
716 bool IsPrefixedBy_NoCase(const wchar_t *s) const { return IsString1PrefixedByString2_NoCase(_chars, s); }
722 const wchar_t *s = _chars;
728 int Find(wchar_t c) const { return FindCharPosInString(_chars, c); }
729 int Find(wchar_t c, unsigned startIndex) const
735 int ReverseFind(wchar_t c) const throw();
739 int Find(const wchar_t *s) const { return Find(s, 0); }
740 int Find(const wchar_t *s, unsigned startIndex) const throw();
750 void InsertAtFront(wchar_t c);
751 // void Insert_wchar_t(unsigned index, wchar_t c);
752 void Insert(unsigned index, const wchar_t *s);
755 void RemoveChar(wchar_t ch) throw();
757 void Replace(wchar_t oldChar, wchar_t newChar) throw();
793 // UString_Wipe &operator=(const wchar_t *s) { UString::operator=(s); return *this; }
802 inline bool operator==(const UString &s1, const wchar_t *s2) { return wcscmp(s1, s2) == 0; }
803 inline bool operator==(const wchar_t *s1, const UString &s2) { return wcscmp(s1, s2) == 0; }
806 inline bool operator!=(const UString &s1, const wchar_t *s2) { return wcscmp(s1, s2) != 0; }
807 inline bool operator!=(const wchar_t *s1, const UString &s2) { return wcscmp(s1, s2) != 0; }
812 void operator==(wchar_t c1, const UString &s2);
813 void operator==(const UString &s1, wchar_t c2);
815 void operator+(wchar_t c, const UString &s); // this function can be OK, but we don't use it
827 void operator-(const UString &s1, wchar_t c);
830 // can we forbid these functions, if wchar_t is 32-bit ?
847 wchar_t *_chars;
860 UString2 &operator=(wchar_t c);
874 UString2(const wchar_t *s);
882 // operator const wchar_t *() const { return _chars; }
883 const wchar_t *GetRawPtr() const { return _chars; }
885 int Compare(const wchar_t *s) const { return wcscmp(_chars, s); }
887 wchar_t *GetBuf(unsigned minLen)
895 UString2 &operator=(const wchar_t *s);
901 bool operator==(const UString2 &s1, const wchar_t *s2);
902 bool operator==(const wchar_t *s1, const UString2 &s2);
905 inline bool operator!=(const UString2 &s1, const wchar_t *s2) { return !(s1 == s2); }
906 inline bool operator!=(const wchar_t *s1, const UString2 &s2) { return !(s1 == s2); }
911 void operator==(wchar_t c1, const UString2 &s2);
912 void operator==(const UString2 &s1, wchar_t c2);
917 void operator+(const UString2 &s1, const wchar_t *s2);
918 void operator+(const wchar_t *s1, const UString2 &s2);
919 void operator+(wchar_t c, const UString2 &s);
920 void operator+(const UString2 &s, wchar_t c);
925 void operator-(const UString2 &s1, wchar_t c);
956 typedef wchar_t FChar;
1018 FString us2fs(const wchar_t *s);
1042 bool FindWord_In_LowCaseAsciiList_NoCase(const char *list, const wchar_t *str);
1053 // WCHAR_MAX is defined as ((wchar_t)-1)
1062 #define WCHAR_IN_FILE_NAME_BACKSLASH_REPLACEMENT ((wchar_t)((unsigned)(0xF000) + (unsigned)'\\'))