summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichal Klocek <michal.klocek@qt.io>2022-11-03 14:28:48 +0100
committerMichal Klocek <michal.klocek@qt.io>2022-11-22 08:24:33 +0100
commit247e598a74b65ec82e10c03243a36038c13361f0 (patch)
tree11da812b26fda177d72501e5af11046ae7cff435
parent6193ceb67b3d30904931c34aa2c7f5f97237d3e8 (diff)
Doc: Update the docs related to the Favicon
Fixes: QTBUG-106501 Pick-to: 6.4 Change-Id: Ib70020d947b3010d22315db3bd32c017e55f71c7 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
-rw-r--r--src/core/doc/src/qtwebengine-features.qdoc29
1 files changed, 23 insertions, 6 deletions
diff --git a/src/core/doc/src/qtwebengine-features.qdoc b/src/core/doc/src/qtwebengine-features.qdoc
index 33f1a54fa..4250d92a6 100644
--- a/src/core/doc/src/qtwebengine-features.qdoc
+++ b/src/core/doc/src/qtwebengine-features.qdoc
@@ -15,7 +15,7 @@
\li \l{Client Certificates}
\li \l{Custom Schemes}
\li \l{Drag and Drop}
- \li \l{Favicon Handling}
+ \li \l{Favicon}
\li \l{Fullscreen}
\li \l{Hardware Acceleration}
\li \l{HTML5 DRM}
@@ -158,25 +158,37 @@
Support for this feature was added in Qt 5.7.0.
- \section1 Favicon Handling
+ \section1 Favicon
+
+ \QWE supports the web site URL icon, \e favicon. Each icon is stored in the internal
+ database for each \l QWebEngieProfile and can be accessed using a \l QWebEnginePage::icon()
+ call or a \l {WebEngineView::icon}{WebEngineView.icon} property for the currently loaded content.
+
+ Moreover \QWE provides API for accessing already stored icons in the internal profile's database.
+
+ \note The icon database is not available for off-the-record profiles.
+
+ \section2 QML Favicon Handling
For accessing icons a \c QQuickImageProvider is registered. This provider can be
accessed by a special URL where the scheme is "image:" and the host is "favicon".
- For example,
+
\qml
Image {
source: "image://favicon/url"
}
\endqml
- The \c url can be the URL of the favicon. For example,
+ The \c url can be the URL of the favicon:
+
\qml
Image {
source: "image://favicon/https://www.qt.io/hubfs/2016_Qt_Logo/qt_logo_green_rgb_16x16.png"
}
\endqml
- The \c url also can be a page URL to access its icon. For example,
+ The \c url also can be a page URL to access its icon:
+
\qml
Image {
source: "image://favicon/https://www.qt.io/"
@@ -194,7 +206,12 @@
can be accessed without network connection too. The icon must be previously loaded
to be stored in the database.
- \note The icon database is not available for off-the-record profiles.
+ \section2 C++ Favicon Handling
+
+ A user can request an icon from the previously loaded content for each
+ \l QWebEngineProfile using the \l QWebEngineProfile::requestIconForPageURL() or
+ \l QWebEngineProfile::requestIconForIconURL() calls. Note that the profile's database is
+ stored in the persistent storage and can be accessed without a network connection.
\section1 Fullscreen