[Qt-interest] XML encoding of UTF8
Jason H
scorp1us at yahoo.com
Wed Aug 18 20:21:41 CEST 2010
I need to "bump" this, and clarify.
My input has #233, my internal processing has it decoded, and my output, which
needs to be a QByteArray, needs to ahve it translated back to "é"
Currently, it is being sent as 'é' (Actually a 2-byte char sequence). I want the
6 byte "é" sequence in the output.
QDomDocument::toByteArray() is not doing it.
----- Original Message ----
From: Jason H <scorp1us at yahoo.com>
To: qt-interest at trolltech.com
Sent: Tue, August 17, 2010 12:45:19 PM
Subject: [Qt-interest] XML encoding of UTF8
I need to represent é (html: eacute, utf8: #233) in a QByteArray.
Here's what's happening. I get an XML/utf-8 file, read it, parse & modify it as
XML in QDomDocument, then I need to serialize it back out. When I do, I call
domDoc.toString().toUtf8().
But this leaves the raw UTF8 two-byte value in there. I need some way to have
the é re-encoded as é But not just that entity, all of them.
How/Does Qt do this?
Thanks!
_______________________________________________
Qt-interest mailing list
Qt-interest at trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-interest
More information about the Qt-interest-old
mailing list