[Interest] QWebSocket text methods should be utf8?
Giuseppe D'Angelo
giuseppe.dangelo at kdab.com
Mon Feb 17 11:27:01 CET 2020
Il 15/02/20 15:46, Roland Hughes ha scritto:
> The QString class, by virtue of the little yippy-yappy dogs it is
> running on isn't big-endian hence your continually calling toUtf8().
Endianess has nothing to do with this:
1) QString is UTF-16 encoded (in host byte order). The whole ordeal is
that it's *not* UTF-8, therefore it needs to transcode from it (even on
big-endian systems).
2) UTF-8 has the same byte order everywhere.
Cheers,
--
Giuseppe D'Angelo | giuseppe.dangelo at kdab.com | Senior Software Engineer
KDAB (France) S.A.S., a KDAB Group company
Tel. France +33 (0)4 90 84 08 53, http://www.kdab.com
KDAB - The Qt, C++ and OpenGL Experts
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 4329 bytes
Desc: Firma crittografica S/MIME
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20200217/7868a9c1/attachment.bin>
More information about the Interest
mailing list