added wxUniChar::AsUTF8() for easy conversion in UTF8 build
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@46376 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -190,13 +190,14 @@ bool wxStringOperationsUtf8::IsValidUtf8LeadByte(unsigned char c)
|
||||
#endif
|
||||
|
||||
|
||||
wxStringOperationsUtf8::Utf8CharBuffer
|
||||
wxStringOperationsUtf8::EncodeChar(const wxUniChar& ch)
|
||||
// NB: this is in this file and not unichar.cpp to keep all UTF-8 encoding
|
||||
// code in single place
|
||||
wxUniChar::Utf8CharBuffer wxUniChar::AsUTF8() const
|
||||
{
|
||||
Utf8CharBuffer buf;
|
||||
char *out = buf.data;
|
||||
|
||||
wxUniChar::value_type code = ch.GetValue();
|
||||
value_type code = GetValue();
|
||||
|
||||
// Char. number range | UTF-8 octet sequence
|
||||
// (hexadecimal) | (binary)
|
||||
|
Reference in New Issue
Block a user