Fixed encoding of UTF-16
As per http://en.sfml-dev.org/forums/index.php?topic=19223.0
This commit is contained in:
parent
9c5c750e60
commit
127bc77497
@ -322,7 +322,7 @@ In Utf<16>::decode(In begin, In end, Uint32& output, Uint32 replacement)
|
|||||||
template <typename Out>
|
template <typename Out>
|
||||||
Out Utf<16>::encode(Uint32 input, Out output, Uint16 replacement)
|
Out Utf<16>::encode(Uint32 input, Out output, Uint16 replacement)
|
||||||
{
|
{
|
||||||
if (input < 0xFFFF)
|
if (input <= 0xFFFF)
|
||||||
{
|
{
|
||||||
// The character can be copied directly, we just need to check if it's in the valid range
|
// The character can be copied directly, we just need to check if it's in the valid range
|
||||||
if ((input >= 0xD800) && (input <= 0xDFFF))
|
if ((input >= 0xD800) && (input <= 0xDFFF))
|
||||||
|
Loading…
Reference in New Issue
Block a user