Jacek Caban (@jacek) commented about dlls/mshtml/htmldoc.c:
+ nsAString_Init(&nsstr, NULL); + nsres = nsIDOMDocument_GetContentType(nsdoc, &nsstr); + assert(nsres == NS_OK); + + nsAString_GetData(&nsstr, &str); + if(!wcscmp(str, L"text/html")) + doc_type = DOCTYPE_HTML; + else if(!wcscmp(str, L"application/xhtml+xml")) + doc_type = DOCTYPE_XHTML; + else if(!wcscmp(str, L"image/svg+xml")) + doc_type = DOCTYPE_SVG; + else + doc_type = DOCTYPE_XML; + nsAString_Finish(&nsstr); + return doc_type; +} The only user, `create_document_node` already knows if it's a HTML document from QI. I guess if we'd go with `is_xml`, we could just do something like `strstr(getContentType(), "xml")` in case of HTML document to know if it's XHTML.
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/8821#note_113991