Final set of selected documentation fixes for qtbase
from Qt 4.8 commit
bacae725e584f51ee2fd83af7bef3e4515de9587
Task-number: QTBUG-13362
Task-number: QTBUG-18356
Task-number: QTBUG-18417
Task-number: QTBUG-18664
Task-number: QTBUG-21562
Task-number: QTBUG-22094
Task-number: QTBUG-18741
Task-number: QTBUG-15921
Task-number: QTBUG-15738
Change-Id: I3bd33bb7ce7aa991913ba82f3ea0e4b124f3ee41
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
As described in the \l{Model Subclassing Reference}, models must
provide implementations for the standard set of model functions:
\l{QAbstractItemModel::}{flags()}, \l{QAbstractItemModel::}{data()},
As described in the \l{Model Subclassing Reference}, models must
provide implementations for the standard set of model functions:
\l{QAbstractItemModel::}{flags()}, \l{QAbstractItemModel::}{data()},
- \l{QAbstractItemModel::}{headerData()}, and
+ \l{QAbstractItemModel::}{headerData()},
+ \l{QAbstractItemModel::}{columnCount()}, and
\l{QAbstractItemModel::}{rowCount()}. In addition, hierarchical models,
such as this one, need to provide implementations of
\l{QAbstractItemModel::}{index()} and \l{QAbstractItemModel::}{parent()}.
An editable model needs to provide implementations of
\l{QAbstractItemModel::}{setData()} and
\l{QAbstractItemModel::}{rowCount()}. In addition, hierarchical models,
such as this one, need to provide implementations of
\l{QAbstractItemModel::}{index()} and \l{QAbstractItemModel::}{parent()}.
An editable model needs to provide implementations of
\l{QAbstractItemModel::}{setData()} and
- \l{QAbstractItemModel::}{headerData()}, and must return a suitable
+ \l{QAbstractItemModel::}{setHeaderData()}, and must return a suitable
combination of flags from its \l{QAbstractItemModel::}{flags()} function.
Since this example allows the dimensions of the model to be changed,
combination of flags from its \l{QAbstractItemModel::}{flags()} function.
Since this example allows the dimensions of the model to be changed,
In this case, the file is accessible as \c
:/myresources/cut-img.png.
In this case, the file is accessible as \c
:/myresources/cut-img.png.
- Some resources, such as translation files and icons, many need to
- change based on the user's locale. This is done by adding a \c lang
+ Some resources need to change based on the user's locale,
+ such as translation files or icons. This is done by adding a \c lang
attribute to the \c qresource tag, specifying a suitable locale
string. For example:
attribute to the \c qresource tag, specifying a suitable locale
string. For example:
switch (flag) {
case 0:
case 1:
switch (flag) {
case 0:
case 1:
- mutex.unlock();
- return moreComplexFunction(flag);
+ retVal = moreComplexFunction(flag);
+ break;
case 2:
{
int status = anotherFunction();
case 2:
{
int status = anotherFunction();
\snippet doc/src/snippets/code/doc_src_sql-driver.qdoc 15
Users of MinGW may wish to consult the following online document:
\snippet doc/src/snippets/code/doc_src_sql-driver.qdoc 15
Users of MinGW may wish to consult the following online document:
- \l{Compiling PostgreSQL On Native Win32 FAQ}.
+ \l{PostgreSQL MinGW/Native Windows}.
\bold{Note:} This database plugin is not supported for Windows CE.
\bold{Note:} This database plugin is not supported for Windows CE.
Wildcard matching can be convenient because of its simplicity, but
any wildcard regexp can be defined using full regexps, e.g.
Wildcard matching can be convenient because of its simplicity, but
any wildcard regexp can be defined using full regexps, e.g.
- \bold{.*\.html$}. Notice that we can't match both \c .html and \c
+ \bold{.*\\.html$}. Notice that we can't match both \c .html and \c
.htm files with a wildcard unless we use \bold{*.htm*} which will
also match 'test.html.bak'. A full regexp gives us the precision
we need, \bold{.*\\.html?$}.
.htm files with a wildcard unless we use \bold{*.htm*} which will
also match 'test.html.bak'. A full regexp gives us the precision
we need, \bold{.*\\.html?$}.
/*!
\fn QList<QNetworkProxy> QNetworkProxyFactory::queryProxy(const QNetworkProxyQuery &query)
/*!
\fn QList<QNetworkProxy> QNetworkProxyFactory::queryProxy(const QNetworkProxyQuery &query)
- This function examines takes the query request, \a query,
+ This function takes the query request, \a query,
examines the details of the type of socket or request and returns
a list of QNetworkProxy objects that indicate the proxy servers to
be used, in order of preference.
examines the details of the type of socket or request and returns
a list of QNetworkProxy objects that indicate the proxy servers to
be used, in order of preference.
/*!
\fn QList<QNetworkProxy> QNetworkProxyFactory::systemProxyForQuery(const QNetworkProxyQuery &query)
/*!
\fn QList<QNetworkProxy> QNetworkProxyFactory::systemProxyForQuery(const QNetworkProxyQuery &query)
- This function examines takes the query request, \a query,
+ This function takes the query request, \a query,
examines the details of the type of socket or request and returns
a list of QNetworkProxy objects that indicate the proxy servers to
be used, in order of preference.
examines the details of the type of socket or request and returns
a list of QNetworkProxy objects that indicate the proxy servers to
be used, in order of preference.
- This function examines takes the query request, \a query,
+ This function takes the query request, \a query,
examines the details of the type of socket or request and returns
a list of QNetworkProxy objects that indicate the proxy servers to
be used, in order of preference.
examines the details of the type of socket or request and returns
a list of QNetworkProxy objects that indicate the proxy servers to
be used, in order of preference.
- Returns the modal dialog's result code, \c Accepted or \c Rejected.
+ In general returns the modal dialog's result code, \c Accepted or
+ \c Rejected.
+
+ \note When called on a QMessageBox instance, the returned value is a
+ value of the \l QMessageBox::StandardButton enum.
Do not call this function if the dialog was constructed with the
Qt::WA_DeleteOnClose attribute.
Do not call this function if the dialog was constructed with the
Qt::WA_DeleteOnClose attribute.
When using QMessageBox with custom buttons, this function returns an
opaque value; use clickedButton() to determine which button was clicked.
When using QMessageBox with custom buttons, this function returns an
opaque value; use clickedButton() to determine which button was clicked.
+ \note The result() function returns also \l StandardButton value instead
+ of \l QDialog::DialogCode.
+
Users cannot interact with any other window in the same
application until they close the dialog, either by clicking a
button or by using a mechanism provided by the window system.
Users cannot interact with any other window in the same
application until they close the dialog, either by clicking a
button or by using a mechanism provided by the window system.
\property QWidget::enabled
\brief whether the widget is enabled
\property QWidget::enabled
\brief whether the widget is enabled
- An enabled widget handles keyboard and mouse events; a disabled
- widget does not.
+ In general an enabled widget handles keyboard and mouse events; a disabled
+ widget does not. An exception is made with \l{QAbstractButton}.
Some widgets display themselves differently when they are
disabled. For example a button might draw its label grayed out. If
Some widgets display themselves differently when they are
disabled. For example a button might draw its label grayed out. If
checkable buttons can be checked and unchecked (see below).
\o isEnabled() indicates whether the button can be pressed by the
checkable buttons can be checked and unchecked (see below).
\o isEnabled() indicates whether the button can be pressed by the
+ user. \note As opposed to other widgets, buttons derived from
+ QAbstractButton accepts mouse and context menu events
+ when disabled.
\o setAutoRepeat() sets whether the button will auto-repeat if the
user holds it down. \l autoRepeatDelay and \l autoRepeatInterval
\o setAutoRepeat() sets whether the button will auto-repeat if the
user holds it down. \l autoRepeatDelay and \l autoRepeatInterval
element is available using documentElement(). The textual
representation of the document can be obtained using toString().
element is available using documentElement(). The textual
representation of the document can be obtained using toString().
+ \note The DOM tree might end up reserving a lot of memory if the XML
+ document is big. For such documents, the QXmlStreamReader or the
+ QXmlQuery classes might be better solutions.
+
It is possible to insert a node from another document into the
document using importNode().
It is possible to insert a node from another document into the
document using importNode().