Details
-
Task
-
Resolution: Unresolved
-
P3: Somewhat important
-
None
-
None
-
None
Description
QDomDocument should explicitly list all deviations from the Level 1 and Level 2 standards, or the XML standard. Currently the only hint of deviations are in QDomDocument, which says:
The QDom classes have a few issues of nonconformance with the XML specifications that cannot be fixed in Qt 4 without breaking backward compatibility.
Known deviations:
- QDomDocument::setContent() by default does ignore whitespace. The XML standard mandates though that "An XML processor MUST always pass all characters in a document that are not markup through to the application.". One needs to set QDomImplementation::setWhitespacePolicy(QDomImplementation::WhitespacePolicy::Preserve) to change that.
- Furthermore, all QDomDocument::setContent() treats all Unicode whitespace characters as whitespace. The XML standard, however defines whitespace to be only (#x20 | #x9 | #xD | #xA): https://www.w3.org/TR/xml11/#NT-S .