Doc: Fix various documentation issues
- Document QIODeviceBase - Document QPointerEvent::points - Fix linking issues Task-number: QTBUG-90662 Change-Id: Ib123d5708953b22e01f95c82626b39a49fff95b2 Reviewed-by: Nico Vertriest <nico.vertriest@qt.io>
This commit is contained in:
parent
0bd705d91b
commit
00e10f62b5
@ -842,7 +842,7 @@
|
|||||||
If \c fileName is not empty, we create a QFile object, \c file, with
|
If \c fileName is not empty, we create a QFile object, \c file, with
|
||||||
\c fileName. QFile works with QDataStream as QFile is a QIODevice.
|
\c fileName. QFile works with QDataStream as QFile is a QIODevice.
|
||||||
|
|
||||||
Next, we attempt to open the file in \l{QIODevice::}{WriteOnly} mode.
|
Next, we attempt to open the file in \l{QIODeviceBase::}{WriteOnly} mode.
|
||||||
If this is unsuccessful, we display a QMessageBox to inform the user.
|
If this is unsuccessful, we display a QMessageBox to inform the user.
|
||||||
|
|
||||||
\snippet tutorials/addressbook/part6/addressbook.cpp saveToFile() function part2
|
\snippet tutorials/addressbook/part6/addressbook.cpp saveToFile() function part2
|
||||||
@ -869,7 +869,7 @@
|
|||||||
\image addressbook-tutorial-part6-load.png
|
\image addressbook-tutorial-part6-load.png
|
||||||
|
|
||||||
If \c fileName is not empty, again, we use a QFile object, \c file, and
|
If \c fileName is not empty, again, we use a QFile object, \c file, and
|
||||||
attempt to open it in \l{QIODevice::}{ReadOnly} mode. Similar to our
|
attempt to open it in \l{QIODeviceBase::}{ReadOnly} mode. Similar to our
|
||||||
implementation of \c saveToFile(), if this attempt is unsuccessful, we
|
implementation of \c saveToFile(), if this attempt is unsuccessful, we
|
||||||
display a QMessageBox to inform the user.
|
display a QMessageBox to inform the user.
|
||||||
|
|
||||||
@ -939,7 +939,7 @@
|
|||||||
choose a location for the file. Using the file name chosen, we create an
|
choose a location for the file. Using the file name chosen, we create an
|
||||||
instance of QFile to write to.
|
instance of QFile to write to.
|
||||||
|
|
||||||
We attempt to open the file in \l{QIODevice::}{WriteOnly} mode. If this
|
We attempt to open the file in \l{QIODeviceBase::}{WriteOnly} mode. If this
|
||||||
process fails, we display a QMessageBox to inform the user about the
|
process fails, we display a QMessageBox to inform the user about the
|
||||||
problem and return. Otherwise, we pass the file as a parameter to a
|
problem and return. Otherwise, we pass the file as a parameter to a
|
||||||
QTextStream object, \c out. Like QDataStream, the QTextStream class
|
QTextStream object, \c out. Like QDataStream, the QTextStream class
|
||||||
|
@ -289,11 +289,19 @@ QIODevicePrivate::~QIODevicePrivate()
|
|||||||
\sa QBuffer, QFile, QTcpSocket
|
\sa QBuffer, QFile, QTcpSocket
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/*!
|
||||||
|
\class QIODeviceBase
|
||||||
|
\inheaderfile QIODevice
|
||||||
|
\inmodule QtCore
|
||||||
|
\brief Base class for QIODevice that provides flags describing the mode in
|
||||||
|
which a device is opened.
|
||||||
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\enum QIODeviceBase::OpenModeFlag
|
\enum QIODeviceBase::OpenModeFlag
|
||||||
|
|
||||||
This enum is used with open() to describe the mode in which a device
|
This enum is used with QIODevice::open() to describe the mode in which a
|
||||||
is opened. It is also returned by openMode().
|
device is opened. It is also returned by QIODevice::openMode().
|
||||||
|
|
||||||
\value NotOpen The device is not open.
|
\value NotOpen The device is not open.
|
||||||
\value ReadOnly The device is open for reading.
|
\value ReadOnly The device is open for reading.
|
||||||
|
@ -509,7 +509,7 @@ QDebug operator<<(QDebug dbg, const QMargins &m)
|
|||||||
Returns \c true if all margins are very close to 0; otherwise returns
|
Returns \c true if all margins are very close to 0; otherwise returns
|
||||||
false.
|
false.
|
||||||
|
|
||||||
\sa qFuzzyIsNull
|
\sa {<QtGlobal>::}{qFuzzyIsNull}
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
@ -670,7 +670,7 @@ QDebug operator<<(QDebug dbg, const QMargins &m)
|
|||||||
Returns a QMarginsF object that is formed by dividing the components of
|
Returns a QMarginsF object that is formed by dividing the components of
|
||||||
the given \a lhs margins by the given \a rhs divisor.
|
the given \a lhs margins by the given \a rhs divisor.
|
||||||
|
|
||||||
The \a divisor must not be either zero or NaN.
|
The divisor must be neither zero nor NaN.
|
||||||
|
|
||||||
\sa QMarginsF::operator*=(), QMarginsF::operator/=()
|
\sa QMarginsF::operator*=(), QMarginsF::operator/=()
|
||||||
*/
|
*/
|
||||||
|
@ -769,7 +769,7 @@ bool QImageReader::decideFormatFromContent() const
|
|||||||
otherwise left unchanged.
|
otherwise left unchanged.
|
||||||
|
|
||||||
If the device is not already open, QImageReader will attempt to
|
If the device is not already open, QImageReader will attempt to
|
||||||
open the device in \l QIODevice::ReadOnly mode by calling
|
open the device in \l {QIODeviceBase::}{ReadOnly} mode by calling
|
||||||
open(). Note that this does not work for certain devices, such as
|
open(). Note that this does not work for certain devices, such as
|
||||||
QProcess, QTcpSocket and QUdpSocket, where more logic is required
|
QProcess, QTcpSocket and QUdpSocket, where more logic is required
|
||||||
to open the device.
|
to open the device.
|
||||||
@ -799,7 +799,7 @@ QIODevice *QImageReader::device() const
|
|||||||
/*!
|
/*!
|
||||||
Sets the file name of QImageReader to \a fileName. Internally,
|
Sets the file name of QImageReader to \a fileName. Internally,
|
||||||
QImageReader will create a QFile object and open it in \l
|
QImageReader will create a QFile object and open it in \l
|
||||||
QIODevice::ReadOnly mode, and use this when reading images.
|
{QIODeviceBase::}{ReadOnly} mode, and use this when reading images.
|
||||||
|
|
||||||
If \a fileName does not include a file extension (e.g., .png or .bmp),
|
If \a fileName does not include a file extension (e.g., .png or .bmp),
|
||||||
QImageReader will cycle through all supported extensions until it finds
|
QImageReader will cycle through all supported extensions until it finds
|
||||||
|
@ -252,6 +252,12 @@ QInputEvent::~QInputEvent()
|
|||||||
Returns a QEventPoint reference for the point at index \a i.
|
Returns a QEventPoint reference for the point at index \a i.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/*!
|
||||||
|
\fn const QList<QEventPoint> &QPointerEvent::points() const
|
||||||
|
|
||||||
|
Returns a list of points in this pointer event.
|
||||||
|
*/
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\fn QPointingDevice::PointerType QPointerEvent::pointerType() const
|
\fn QPointingDevice::PointerType QPointerEvent::pointerType() const
|
||||||
|
|
||||||
|
@ -182,7 +182,7 @@ QByteArray QTextDocumentWriter::format () const
|
|||||||
unchanged.
|
unchanged.
|
||||||
|
|
||||||
If the device is not already open, QTextDocumentWriter will attempt to
|
If the device is not already open, QTextDocumentWriter will attempt to
|
||||||
open the device in \l QIODevice::WriteOnly mode by calling open().
|
open the device in \l {QIODeviceBase::}{WriteOnly} mode by calling open().
|
||||||
|
|
||||||
\note This will not work for certain devices, such as QProcess,
|
\note This will not work for certain devices, such as QProcess,
|
||||||
QTcpSocket and QUdpSocket, where some configuration is required before
|
QTcpSocket and QUdpSocket, where some configuration is required before
|
||||||
@ -211,7 +211,8 @@ QIODevice *QTextDocumentWriter::device () const
|
|||||||
/*!
|
/*!
|
||||||
Sets the name of the file to be written to \a fileName. Internally,
|
Sets the name of the file to be written to \a fileName. Internally,
|
||||||
QTextDocumentWriter will create a QFile and open it in \l
|
QTextDocumentWriter will create a QFile and open it in \l
|
||||||
QIODevice::WriteOnly mode, and use this file when writing the document.
|
{QIODeviceBase::}{WriteOnly} mode, and use this file when writing the
|
||||||
|
document.
|
||||||
|
|
||||||
\sa fileName(), setDevice()
|
\sa fileName(), setDevice()
|
||||||
*/
|
*/
|
||||||
|
Loading…
x
Reference in New Issue
Block a user