summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael BrĂ¼ning <michael.bruning@digia.com>2014-05-12 15:02:30 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2014-05-12 19:11:32 +0200
commit6f5e9d0355872be7ab944f08ca1362c6f5bc7879 (patch)
treef012eff87732c66d91b5a25f23276f854c889c8a
parent43db107bcc29a54044b020544e3874048687d8e7 (diff)
Fix up some more documentation.
Removes methods from the documentation that no longer exist. Removes left over instance of Qt WebKit / WebKit instead of Qt WebEngine / Chromium in the documentation. Change-Id: I27e1d41fc16116a60f94c3369f76ddfed60e4380 Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
-rw-r--r--src/webengine/doc/src/qquickwebengineview_lgpl.qdoc142
-rw-r--r--src/webengine/doc/src/qtwebengine.qdoc3
-rw-r--r--src/webenginewidgets/doc/src/qtwebenginewidgets.qdoc6
-rw-r--r--src/webenginewidgets/doc/src/qwebenginehistory_lgpl.qdoc23
-rw-r--r--src/webenginewidgets/doc/src/qwebenginepage_lgpl.qdoc174
-rw-r--r--src/webenginewidgets/doc/src/qwebengineview_lgpl.qdoc50
6 files changed, 130 insertions, 268 deletions
diff --git a/src/webengine/doc/src/qquickwebengineview_lgpl.qdoc b/src/webengine/doc/src/qquickwebengineview_lgpl.qdoc
index 91aef712..2f6ba7f0 100644
--- a/src/webengine/doc/src/qquickwebengineview_lgpl.qdoc
+++ b/src/webengine/doc/src/qquickwebengineview_lgpl.qdoc
@@ -2,7 +2,6 @@
* Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies).
* Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies)
* Copyright (c) 2012 Hewlett-Packard Development Company, L.P.
- * Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
@@ -34,39 +33,27 @@
the screen with other QML components or encompass the full screen as
specified within the QML application.
- It allows an
- application to load pages into the WebEngineView, either by URL or with
- an HTML string, and navigate within session history. By default,
- links to different pages load within the same WebEngineView, but applications
- may intercept requests to delegate links to other functions.
+ It allows an application to load pages into the WebEngineView, either by URL or with
+ an HTML string, and navigate within session history. By default,
+ links to different pages load within the same WebEngineView, but web sites may
+ request them to be opened as a new tab, window or dialog.
The following sample QML application loads a web page, responds to session
- history context, and intercepts requests for external links. It also makes
- use of \l ScrollView from \l {Qt Quick Controls} to add scroll bars for
- the content area.
+ history context.
\code
- import QtQuick 2.0
- import QtQuick.Controls 1.0
+ import QtQuick 2.1
+ import QtQuick.Controls 1.1
import QtWebEngine 1.0
- ScrollView {
+ ApplicationWindow {
width: 1280
height: 720
+ visible: true
WebEngineView {
id: webview
- url: "http://qt-project.org"
+ url: "http://www.qt-project.org"
anchors.fill: parent
- onNavigationRequested: {
- // detect URL scheme prefix, most likely an external link
- var schemaRE = /^\w+:/;
- if (schemaRE.test(request.url)) {
- request.action = WebEngineView.AcceptRequest;
- } else {
- request.action = WebEngineView.IgnoreRequest;
- // delegate request.url here
- }
- }
}
}
\endcode
@@ -204,9 +191,10 @@
\li \c{url}: the location of the resource that is loading.
- \li \c{status}: Reflects one of three load states:
- \c{LoadStartedStatus}, \c{LoadSucceededStatus}, or
- \c{LoadFailedStatus}. See \c{WebEngineView::LoadStatus}.
+ \li \c{status}: Reflects one of four load states:
+ \c{LoadStartedStatus}, \c{LoadStoppedStatus},
+ \c{LoadSucceededStatus}, or \c{LoadFailedStatus}.
+ See \c{WebEngineView::LoadStatus}.
\li \c{errorString}: description of load error.
@@ -234,44 +222,6 @@
*/
/*!
- \qmlsignal WebEngineView::onNavigationRequested(request)
-
- Occurs for various kinds of navigation. If the application listens
- for this signal, it must set the \c{request.action} to either of the
- following \l{WebEngineView::NavigationRequestAction} enum values:
-
- \list
-
- \li \c{AcceptRequest}: Allow navigation to external pages within the
- web view. This represents the default behavior when no listener is
- active.
-
- \li \c{IgnoreRequest}: Suppress navigation to new pages within the web
- view. (The listener may then delegate navigation externally to
- the browser application.)
-
- \endlist
-
- The \a{request} also provides the following read-only values:
-
- \list
-
- \li \c{url}: The location of the requested page.
-
- \li \c{navigationType}: contextual information, one of
- \c{LinkClickedNavigation}, \c{BackForwardNavigation},
- \c{ReloadNavigation}, \c{FormSubmittedNavigation},
- \c{FormResubmittedNavigation}, or \c{OtherNavigation} enum values.
- See \l{WebEngineView::NavigationType}.
-
- \li \c{keyboardModifiers}: potential states for \l{Qt::KeyboardModifier}.
-
- \li \c{mouseButton}: potential states for \l{Qt::MouseButton}.
-
- \endlist
-*/
-
-/*!
\qmlproperty enumeration WebEngineView::ErrorDomain
Details various high-level error types.
@@ -287,7 +237,7 @@
\li Content fails to be interpreted by Qt WebEngine.
\row
- \li NetworkErrorDomain
+ \li ConnectionErrorDomain
\li Error results from faulty network connection.
\row
@@ -295,8 +245,16 @@
\li Error is produced by server.
\row
- \li DownloadErrorDomain
- \li Error in saving file.
+ \li CertificateErrorDomain
+ \li Error related to the SSL/TLS certficate.
+
+ \row
+ \li FtpErrorDomain
+ \li An error related to the file transfer protocol.
+
+ \row
+ \li DnsErrorDomain
+ \li An error related to DNS lookup.
\row
\li NoErrorDomain
@@ -306,9 +264,9 @@
*/
/*!
- \qmlproperty enumeration WebEngineView::NavigationType
+ \qmlproperty enumeration WebEngineView::JavaScriptConsoleMessageLevel
- Distinguishes context for various navigation actions.
+ Indicates the severity of a JavaScript console message.
\table
@@ -317,28 +275,16 @@
\li Description
\row
- \li LinkClickedNavigation
- \li Navigation via link.
+ \li InfoMessageLevel
+ \li Message is purely informative and should be safe to ignore.
\row
- \li FormSubmittedNavigation
- \li Form data is posted.
+ \li WarningMessageLevel
+ \li Message indicates there might be a problem that may need attention.
\row
- \li BackForwardNavigation
- \li Navigation back and forth within session history.
-
- \row
- \li ReloadNavigation
- \li The current page is reloaded.
-
- \row
- \li FormResubmittedNavigation
- \li Form data is re-posted.
-
- \row
- \li OtherNavigation
- \li Unspecified fallback method of navigation.
+ \li ErrorMessageLevel
+ \li Message indicates there has been an error.
\endtable
*/
@@ -368,25 +314,3 @@
\endtable
*/
-
-/*!
- \qmlproperty enumeration WebEngineView::NavigationRequestAction
-
- Specifies a policy when navigating a link to an external page.
-
- \table
-
- \header
- \li Constant
- \li Description
-
- \row
- \li AcceptRequest
- \li Allow navigation to external pages within the web view.
-
- \row
- \li IgnoreRequest
- \li Suppress navigation to new pages within the web view.
-
- \endtable
-*/
diff --git a/src/webengine/doc/src/qtwebengine.qdoc b/src/webengine/doc/src/qtwebengine.qdoc
index 18192d90..789ac4b5 100644
--- a/src/webengine/doc/src/qtwebengine.qdoc
+++ b/src/webengine/doc/src/qtwebengine.qdoc
@@ -1,4 +1,5 @@
/*
+ Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies).
Copyright (C) 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -27,7 +28,7 @@
\title Qt WebEngine QML Types
\brief Provides QML types for rendering web content within a QML application
- The QML types can be imported into your applciation using the following
+ The QML types can be imported into your application using the following
import statement in your .qml file:
\code
diff --git a/src/webenginewidgets/doc/src/qtwebenginewidgets.qdoc b/src/webenginewidgets/doc/src/qtwebenginewidgets.qdoc
index 6c39b3a9..4f4d0be5 100644
--- a/src/webenginewidgets/doc/src/qtwebenginewidgets.qdoc
+++ b/src/webenginewidgets/doc/src/qtwebenginewidgets.qdoc
@@ -1,6 +1,6 @@
/****************************************************************************
**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
** This file is part of the documentation of the Qt Toolkit.
@@ -51,8 +51,7 @@
C++ classes to render and interact with web content.
Qt WebEngine Widgets provides a Web browser engine that makes it easy to embed
- content from the World Wide Web into your Qt application. At the same time
- Web content can be enhanced with native controls.
+ content from the World Wide Web into your Qt application.
Qt WebEngine Widgets provides facilities for rendering of HyperText Markup
Language (HTML), Extensible HyperText Markup Language (XHTML) and Scalable
@@ -199,7 +198,6 @@
\brief Examples demonstrating the Qt WebEngine Widgets usage
\ingroup all-examples
- // FIXME: same as above - can we use Chromium / Blink?
Qt provides an integrated Web browser component based on Chromium, the popular
open source browser engine.
diff --git a/src/webenginewidgets/doc/src/qwebenginehistory_lgpl.qdoc b/src/webenginewidgets/doc/src/qwebenginehistory_lgpl.qdoc
index 3ddb45dd..0cc90fb0 100644
--- a/src/webenginewidgets/doc/src/qwebenginehistory_lgpl.qdoc
+++ b/src/webenginewidgets/doc/src/qwebenginehistory_lgpl.qdoc
@@ -24,7 +24,6 @@
/*!
\class QWebEngineHistoryItem
- \since 4.4
\brief The QWebEngineHistoryItem class represents one item in the history of a QWebEnginePage
\inmodule QtWebEngine
@@ -95,13 +94,11 @@
/*!
\fn bool QWebEngineHistoryItem::isValid() const
- \since 4.5
Returns whether this is a valid history item.
*/
/*!
\class QWebEngineHistory
- \since 4.4
\brief The QWebEngineHistory class represents the history of a QWebEnginePage
\inmodule QtWebEngine
@@ -217,7 +214,6 @@
/*!
\fn int QWebEngineHistory::currentItemIndex() const
- \since 4.5
Returns the index of the current item in history.
*/
@@ -232,24 +228,7 @@
*/
/*!
- \fn int QWebEngineHistory::maximumItemCount() const
- \since 4.5
- Returns the maximum number of items in the history.
-
- \sa setMaximumItemCount()
-*/
-
-/*!
- \fn void QWebEngineHistory::setMaximumItemCount(int count)
- \since 4.5
- Sets the maximum number of items in the history to \a count.
-
- \sa maximumItemCount()
-*/
-
-/*!
\fn QDataStream& operator<<(QDataStream& target, const QWebEngineHistory& history)
- \since 4.6
\relates QWebEngineHistory
\brief The operator<< function streams a history into a data stream.
@@ -261,10 +240,8 @@
/*!
\fn QDataStream& operator>>(QDataStream& source, QWebEngineHistory& history)
\relates QWebEngineHistory
- \since 4.6
\brief The operator>> function loads a history from a data stream.
Loads a QWebEngineHistory from the specified \a stream into the given \a history.
*/
-
diff --git a/src/webenginewidgets/doc/src/qwebenginepage_lgpl.qdoc b/src/webenginewidgets/doc/src/qwebenginepage_lgpl.qdoc
index 3019ed5e..538df951 100644
--- a/src/webenginewidgets/doc/src/qwebenginepage_lgpl.qdoc
+++ b/src/webenginewidgets/doc/src/qwebenginepage_lgpl.qdoc
@@ -26,7 +26,6 @@
/*!
\class QWebEnginePage
- \since 4.4
\brief The QWebEnginePage class provides an object to view and edit web documents.
\inmodule QtWebEngine
@@ -40,7 +39,6 @@
\l{QWebEngineView::pageAction()}{pageAction}() in QWebEngineView), triggerAction(),
findText() and settings().
-
A page can be loaded using load() or setUrl(). Alternatively, if you have
the HTML content readily available, you can use setHtml() instead.
@@ -63,11 +61,6 @@
For access to the underlying DOM tree, there is documentElement(),
findAllElements() and findFirstElement().
- A QWebEnginePage can be printed onto a QPrinter using the print() function.
- This function is marked as a slot and can be conveniently connected to
- \l{QPrintPreviewDialog}'s \l{QPrintPreviewDialog::}{paintRequested()}
- signal.
-
The loadStarted() signal is emitted when the page begins to load.The
loadProgress() signal, on the other hand, is emitted whenever an element
of the web page completes loading, such as an embedded image, a script,
@@ -75,55 +68,37 @@
are loaded completely, independent of script execution or page rendering.
Its argument, either true or false, indicates whether or not the load
operation succeeded.
-
- \section1 Using QWebEnginePage in a Widget-less Environment
-
- Before you begin painting a QWebEnginePage object, you need to set the size of
- the viewport by calling setViewportSize(). Then, you invoke the main
- frame's render function (QWebEnginePage::render()). An example of this
- is shown in the code snippet below.
-
- Suppose we have a \c Thumbnail class as follows:
-
- \snippet snippets/webpage/main.cpp 0
-
- The \c Thumbnail's constructor takes in a \a url. We connect our QWebEnginePage
- object's \l{QWebEnginePage::}{loadFinished()} signal to our private slot,
- \c render().
-
- \snippet snippets/webpage/main.cpp 1
-
- The \c render() function shows how we can paint a thumbnail using a
- QWebEnginePage object.
-
- \snippet snippets/webpage/main.cpp 2
-
- We begin by setting the \l{QWebEnginePage::viewportSize()}{viewportSize} and
- then we instantiate a QImage object, \c image, with the same size as our
- \l{QWebEnginePage::viewportSize()}{viewportSize}. This image is then sent
- as a parameter to \c painter. Next, we render the contents of the main
- frame and its subframes into \c painter. Finally, we save the scaled image.
-*/
-
-/*!
- \fn QMenu *QWebEnginePage::createStandardContextMenu()
- \since 4.5
- This function creates the standard context menu which is shown when
- the user clicks on the web page with the right mouse button. It is
- called from the default contextMenuEvent() handler. The popup menu's
- ownership is transferred to the caller.
- */
-
-/*!
- \fn QVariant QWebEnginePage::inputMethodQuery(Qt::InputMethodQuery property) const
- This method is used by the input method to query a set of properties of the page
- to be able to support complex input method operations as support for surrounding
- text and reconversions.
-
- \a property specifies which property is queried.
-
- \sa QWidget::inputMethodEvent(), QInputMethodEvent, QInputContext
*/
+// FIXME: This part is commented out for the time being until we decide if and how
+// the functionality to render a page onto a painter will be reintroduced or not.
+//
+// \section1 Using QWebEnginePage in a Widget-less Environment
+//
+// Before you begin painting a QWebEnginePage object, you need to set the size of
+// the viewport by calling setViewportSize(). Then, you invoke the main
+// frame's render function (QWebEnginePage::render()). An example of this
+// is shown in the code snippet below.
+//
+// Suppose we have a \c Thumbnail class as follows:
+//
+// \snippet snippets/webpage/main.cpp 0
+//
+// The \c Thumbnail's constructor takes in a \a url. We connect our QWebEnginePage
+// object's \l{QWebEnginePage::}{loadFinished()} signal to our private slot,
+// \c render().
+//
+// \snippet snippets/webpage/main.cpp 1
+//
+// The \c render() function shows how we can paint a thumbnail using a
+// QWebEnginePage object.
+//
+// \snippet snippets/webpage/main.cpp 2
+//
+// We begin by setting the \l{QWebEnginePage::viewportSize()}{viewportSize} and
+// then we instantiate a QImage object, \c image, with the same size as our
+// \l{QWebEnginePage::viewportSize()}{viewportSize}. This image is then sent
+// as a parameter to \c painter. Next, we render the contents of the main
+// frame and its subframes into \c painter. Finally, we save the scaled image.
/*!
\enum QWebEnginePage::FindFlag
@@ -150,14 +125,14 @@
\value Forward Navigate forward in the history of navigated links.
\value Stop Stop loading the current page.
\value Reload Reload the current page.
- \value ReloadAndBypassCache Reload the current page, but do not use any local cache. (Added in Qt 4.6)
+ \value ReloadAndBypassCache Reload the current page, but do not use any local cache.
\value Cut Cut the content currently selected into the clipboard.
\value Copy Copy the content currently selected into the clipboard.
\value Paste Paste content from the clipboard.
\value Undo Undo the last editing action.
\value Redo Redo the last editing action.
\value SelectAll Selects all content.
- \value PasteAndMatchStyle Paste content from the clipboard with current style. (Added in Qt 4.6)
+ \value PasteAndMatchStyle Paste content from the clipboard with current style.
\omitvalue WebActionCount
@@ -174,6 +149,28 @@
*/
/*!
+ \enum QWebEnginePage::JavaScriptConsoleMessageLevel
+
+ This enum describes the different severity levels a JavaScript console message can have.
+
+ \value InfoMessageLevel The message is purely informative and can safely be ignored.
+ \value WarningMessageLevel The message informs about unexpected behaviors or errors that may need attention.
+ \value ErrorMessageLevel The message indicates there has been an error.
+*/
+
+/*!
+ \enum QWebEnginePage::FileSelectionMode
+
+ This enum indicates whether the implementation of the chooseFiles function should
+ return only one file or may return multiple files.
+
+ \value FileSelectOpen The implementation should return only one file name.
+ \value FileSelectOpenMultiple The implementation may return multiple file names.
+
+ \sa chooseFiles()
+*/
+
+/*!
\fn QWebEnginePage::QWebEnginePage(QObject *parent)
Constructs an empty QWebEnginePage with parent \a parent.
*/
@@ -203,11 +200,22 @@
*/
/*!
- \fn void QWebEnginePage::javaScriptConsoleMessage(const QString& message, int lineNumber, const QString& sourceID)
+ \fn QMenu *QWebEnginePage::createStandardContextMenu()
+ This function creates the standard context menu which is shown when
+ the user clicks on the web page with the right mouse button. It is
+ called from the default contextMenuEvent() handler. The popup menu's
+ ownership is transferred to the caller.
+ */
+
+/*!
+ \fn void QWebEnginePage::javaScriptConsoleMessage(JavaScriptConsoleMessageLevel level, const QString& message, int lineNumber, const QString& sourceID)
This function is called whenever a JavaScript program tries to print a \a message to the web browser's console.
For example in case of evaluation errors the source URL may be provided in \a sourceID as well as the \a lineNumber.
+ \a level indicates the severity of the event that triggered the message, i.e. if it
+ was triggered by an error or a less severe event.
+
The default implementation prints nothing.
*/
@@ -241,16 +249,13 @@
/*!
\fn QWebEnginePage *QWebEnginePage::createWindow(WebWindowType type)
- This function is called whenever WebKit wants to create a new window of the given \a type, for
- example when a JavaScript program requests to open a document in a new window.
+ This function is called whenever the WebEngine wants to create a new window of the given \a type, for example when a JavaScript program requests to open a document in a new window.
If the new window can be created, the new window's QWebEnginePage is returned; otherwise a null pointer is returned.
If the view associated with the web page is a QWebEngineView object, then the default implementation forwards
the request to QWebEngineView's createWindow() function; otherwise it returns a null pointer.
- If \a type is WebModalDialog, the application must call setWindowModality(Qt::ApplicationModal) on the new window.
-
\note In the cases when the window creation is being triggered by JavaScript, apart from
reimplementing this method application must also set the JavaScriptCanOpenWindows attribute
of QWebEngineSettings to true in order for it to get called.
@@ -261,7 +266,7 @@
/*!
\fn void QWebEnginePage::triggerAction(WebAction action, bool)
This function can be called to trigger the specified \a action.
- It is also called by Qt WebKit if the user triggers the action, for example
+ It is also called by Qt WebEngine if the user triggers the action, for example
through a context menu item.
If \a action is a checkable action then \a checked specified whether the action
@@ -300,30 +305,22 @@
*/
/*!
- \fn bool QWebEnginePage::findText(const QString &subString, FindFlags options)
+ \fn void QWebEnginePage::findText(const QString &subString, FindFlags options, const QWebEngineCallback<bool> &resultCallback)
Finds the specified string, \a subString, in the page, using the given \a options.
- If the HighlightAllOccurrences flag is passed, the function will highlight all occurrences
- that exist in the page. All subsequent calls will extend the highlight, rather than
- replace it, with occurrences of the new string.
-
- If the HighlightAllOccurrences flag is not passed, the function will select an occurrence
- and all subsequent calls will replace the current occurrence with the next one.
-
To clear the selection, just pass an empty string.
- Returns true if \a subString was found; otherwise returns false.
+ The \a resultCallback will be called with a value of true if the \a subString was found; otherwise the callback value will be false.
*/
/*!
- \fn QString QWebEnginePage::chooseFile(QWebEngineFrame *parentFrame, const QString& suggestedFile)
+ \fn QString QWebEnginePage::chooseFiles(FileSelectionMode mode, const QStringList& oldFiles, const QStringList& acceptedMimeTypes)
This function is called when the web content requests a file name, for example
as a result of the user clicking on a "file upload" button in a HTML form.
- A suggested filename may be provided in \a suggestedFile. The frame originating the
- request is provided as \a parentFrame.
+ \a mode indicates whether only one file or multiples files are expected to be returned.
- \sa ChooseMultipleFilesExtension
+ A suggested filename may be provided as the first entry of \a oldFiles.
*/
/*!
@@ -412,7 +409,6 @@
*/
/*!
- \since 4.6
\property QWebEnginePage::requestedUrl
The URL requested to loaded by the frame currently viewed. The URL may differ from
@@ -432,7 +428,7 @@
/*!
\fn void QWebEnginePage::setHtml(const QString &html, const QUrl &baseUrl)
- Sets the content of this frame to \a html. \a baseUrl is optional and used to resolve relative
+ Sets the content of this page's main frame to \a html. \a baseUrl is optional and used to resolve relative
URLs in the document, such as referenced images or stylesheets.
The \a html is loaded immediately; external objects are loaded asynchronously.
@@ -441,7 +437,7 @@
for example due to being blocked by a modal JavaScript alert dialog, this method will return
as soon as possible after the timeout and any subsequent \a html will be loaded asynchronously.
- When using this method WebKit assumes that external resources such as JavaScript programs or style
+ When using this method WebEngie assumes that external resources such as JavaScript programs or style
sheets are encoded in UTF-8 unless otherwise specified. For example, the encoding of an external
script can be specified through the charset attribute of the HTML script tag. It is also possible
for the encoding to be specified by web server.
@@ -458,7 +454,7 @@
/*!
\fn void QWebEnginePage::setContent(const QByteArray &data, const QString &mimeType, const QUrl &baseUrl)
- Sets the content of this frame to the specified content \a data. If the \a mimeType argument
+ Sets the content of this page's main frame to the specified content \a data. If the \a mimeType argument
is empty it is currently assumed that the content is HTML but in future versions we may introduce
auto-detection.
@@ -473,22 +469,24 @@
/*!
\property QWebEnginePage::zoomFactor
- \since 4.5
- \brief the zoom factor for the frame
+ \brief the zoom factor for the main frame
*/
/*!
- \fn QVariant QWebEnginePage::evaluateJavaScript(const QString& scriptSource)
- Evaluates the JavaScript defined by \a scriptSource using this frame as context
- and returns the result of the last executed statement.
+ \fn void runJavaScript(const QString& scriptSource)
+ Runs the JavaScript code contained in \a scriptSource.
+*/
- \sa addToJavaScriptWindowObject(), javaScriptWindowObjectCleared()
+/*!
+ \fn void runJavaScript(const QString& scriptSource, const QWebEngineCallback<const QVariant &> &resultCallback)
+ Runs the JavaScript code contained in \a scriptSource.
+ When the script has been executed, \a resultCallback is called with the result of the last executed statement.
*/
/*!
\fn void QWebEnginePage::titleChanged(const QString &title)
- This signal is emitted whenever the title of the frame changes.
+ This signal is emitted whenever the title of the main frame changes.
The \a title string specifies the new title.
\sa title()
@@ -497,7 +495,7 @@
/*!
\fn void QWebEnginePage::urlChanged(const QUrl &url)
- This signal is emitted with the URL of the frame when the frame's title is
+ This signal is emitted with the URL of the main frame when the main frame's title is
received. The new URL is specified by \a url.
\sa url()
diff --git a/src/webenginewidgets/doc/src/qwebengineview_lgpl.qdoc b/src/webenginewidgets/doc/src/qwebengineview_lgpl.qdoc
index d5bda9bf..7d706608 100644
--- a/src/webenginewidgets/doc/src/qwebengineview_lgpl.qdoc
+++ b/src/webenginewidgets/doc/src/qwebengineview_lgpl.qdoc
@@ -26,14 +26,13 @@
/*!
\class QWebEngineView
- \since 4.4
\brief The QWebEngineView class provides a widget that is used to view and edit
web documents.
\ingroup advanced
\inmodule QtWebEngine
- QWebEngineView is the main widget component of the Qt WebKit web browsing module.
+ QWebEngineView is the main widget component of the Qt WebEngine web browsing module.
It can be used in various applications to display web content live from the
Internet.
@@ -55,10 +54,7 @@
The page() function returns a pointer to the web page object. See
\l{Elements of QWebEngineView} for an explanation of how the web page
- is related to the view. To modify your web view's settings, you can access
- the QWebEngineSettings object with the settings() function. With QWebEngineSettings,
- you can change the default fonts, enable or disable features such as
- JavaScript and plugins.
+ is related to the view.
The title of an HTML document can be accessed with the title() property.
Additionally, a web site may also specify an icon, which can be accessed
@@ -78,25 +74,18 @@
modification of action properties such as \l{QAction::}{text} or
\l{QAction::}{icon}.
- A QWebEngineView can be printed onto a QPrinter using the print() function.
- This function is marked as a slot and can be conveniently connected to
- \l{QPrintPreviewDialog}'s \l{QPrintPreviewDialog::}{paintRequested()}
- signal.
-
If you want to provide support for web sites that allow the user to open
new windows, such as pop-up windows, you can subclass QWebEngineView and
reimplement the createWindow() function.
\section1 Elements of QWebEngineView
- QWebEngineView also consists of a QWebEnginePage.
- It is possible to use QWebEnginePage without using QWebEngineView,
- if you do not require QWidget attributes. Nevertheless, Qt WebKit depends
- on QtGui, so you should use a QApplication instead of QCoreApplication.
+ QWebEngineView contains a QWebEnginePage, which in turn allows access to the
+ QWebEngineHistory in the page's context.
- \sa {Previewer Example}, {WebEngine Tab Browser Example}, {Form Extractor Example},
- {Google Chat Example}, {WebEngine Fancy Browser Example}
*/
+// FIXME: reintroduce the following when we have proper names for the examples.
+// \sa {WebEngine Tab Browser Example}, {WebEngine Fancy Browser Example}
/*!
@@ -147,7 +136,7 @@
The \a html is loaded immediately; external objects are loaded asynchronously.
- When using this method, WebKit assumes that external resources such as
+ When using this method, Qt WebEngine assumes that external resources such as
JavaScript programs or style sheets are encoded in UTF-8 unless otherwise
specified. For example, the encoding of an external script can be specified
through the charset attribute of the HTML script tag. Alternatively, the
@@ -239,33 +228,12 @@
\sa pageAction()
*/
-/*
- \property QWebEngineView::textInteractionFlags
- \brief how the view should handle user input
-
- Specifies how the user can interact with the text on the page.
-*/
-
-
/*!
\property QWebEngineView::zoomFactor
- \since 4.5
\brief the zoom factor for the view
*/
/*!
- \property QWebEngineView::renderHints
- \since 4.6
- \brief the default render hints for the view
-
- These hints are used to initialize QPainter before painting the Web page.
-
- QPainter::TextAntialiasing and QPainter::SmoothPixmapTransform are enabled by default.
-
- \sa QPainter::renderHints()
-*/
-
-/*!
\fn bool QWebEngineView::findText(const QString &subString, QWebEnginePage::FindFlags options)
Finds the specified string, \a subString, in the page, using the given \a options.
@@ -334,10 +302,6 @@
\note If the createWindow() method of the associated page is reimplemented, this
method is not called, unless explicitly done so in the reimplementation.
- \note In the cases when the window creation is being triggered by JavaScript, apart from
- reimplementing this method application must also set the JavaScriptCanOpenWindows attribute
- of QWebEngineSettings to true in order for it to get called.
-
\sa QWebEnginePage::createWindow()
*/