[Qt-interest] Accented characters and QDom in Windows

Ellen Kestrel dragonflykes at gmail.com
Thu Aug 20 17:33:04 CEST 2009


I compiled an application I wrote in linux under Windows the other day, and
there seems to be a problem with the QDom classes I'm using to read and
write files and accented characters.  If I enter in (say) "á" into the
program, save it to a file (where it still appears as "á") and then load it
back into the program, the program now displays it as a box, and the
text-parsing parts of the program do not recognize it as "á".  If I replace
the "á" in the XML file with the appropriate entity (in the form of &#XXX;)
it reads it just fine.  This problem does not occur in linux.

I want to fix this by either:
a) Getting the application to output all accented characters as XML entities
rather than literal strings (how do I do this?)
b) Performing some conversion on the input after it is loaded (which one?)

I haven't been able to figure out how to do these things by perusing the
documentation - can anyone tell me how I would do them?

-EK
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090820/a3bf55cb/attachment.html 


More information about the Qt-interest-old mailing list