From 160e07ca411315f2c46cfecdabcce40fddb53976 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Br=C3=BCning?= Date: Fri, 21 Mar 2014 12:37:07 +0100 Subject: Mention default encoding for QML WebView loadHtml method in docs. The fact that the html string will be implicitly converted to UTF-16 led to some errors with loaded resources. Task-number: QTBUG-36656 Change-Id: I6ed36e2e814034cfccb4082c24e3327674e04cdf Reviewed-by: Leena Miettinen Reviewed-by: Allan Sandfeld Jensen --- Source/WebKit2/UIProcess/API/qt/qquickwebview.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Source/WebKit2/UIProcess/API/qt/qquickwebview.cpp b/Source/WebKit2/UIProcess/API/qt/qquickwebview.cpp index c3cc68a7b..a8dc93c98 100644 --- a/Source/WebKit2/UIProcess/API/qt/qquickwebview.cpp +++ b/Source/WebKit2/UIProcess/API/qt/qquickwebview.cpp @@ -2185,6 +2185,10 @@ void QQuickWebView::handleFlickableMouseRelease(const QPointF& position, qint64 and that was the base url, then an image referenced with the relative url \c diagram.png would be looked for at \c{http://www.example.com/documents/diagram.png}. + It is important to keep in mind that the \a html string will be converted to UTF-16 + internally. Textual resources, such as scripts or style sheets, will be treated as + UTF-16 as well, unless they have an explicit charset property in their referencing tag. + If an \a unreachableUrl is passed it is used as the url for the loaded content. This is typically used to display error pages for a failed load. -- cgit v1.2.1