Doc: Fix documentation issues

Fix the following QDoc warnings:

* warning: Can't link to 'QRhiWidget::sampleConut'
* warning: Can't link to '`Q_NODISCARD_CTOR'
* warning: Invalid '\relates' (already a member of 'QEventLoopLocker')
* warning: Unknown command '\relatesalso'
* warning: Undocumented parameter 'separator' in QLocale::name()
* warning: clang couldn't find function when parsing \fn void QRhiWidget::framePresented()

In QAtomicPointer, work around the issue of QDoc not supporting
multiple \relates command for a single topic by adding a see-also
link to the global qYieldCpu() function.

Document the qvariant_cast() overload taking an rvalue reference.

Change-Id: I2528eee666149a97a14be059bbed537636d7aa0d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
Topi Reinio 2023-09-06 12:44:31 +00:00
parent c7486cd665
commit c46551e203
9 changed files with 17 additions and 10 deletions

View File

@ -31,7 +31,7 @@
\li The contents of the QRhiWidget \l{QRhiWidget::grab()}{can be
read back} and saved to an image file (e.g. a PNG file).
\li 4x multisample antialiasing \l{QRhiWidget::sampleConut}{can be toggled}
\li 4x multisample antialiasing \l{QRhiWidget::sampleCount()}{can be toggled}
at run time. The QRhiWidget subclass is prepared to handle the changing
sample count correctly.

View File

@ -421,7 +421,7 @@
\brief Expand to \c{[[nodiscard(message)]]} on compilers that support the feature.
Otherwise they expand to [[nodiscard]] and Q_NODISCARD_CTOR, respectively.
Otherwise they expand to \c {[[nodiscard]]} and Q_NODISCARD_CTOR, respectively.
\sa`Q_NODISCARD_CTOR
\sa Q_NODISCARD_CTOR
*/

View File

@ -403,7 +403,6 @@ QEventLoopLocker::QEventLoopLocker(QThread *thread) noexcept
/*!
\fn QEventLoopLocker::swap(QEventLoopLocker &lhs, QEventLoopLocker &rhs)
\relates QEventLoopLocker
\since 6.7
Swaps the object and the state of \a lhs with \a rhs.

View File

@ -2722,6 +2722,14 @@ QT_WARNING_POP
\sa QVariant::value()
*/
/*!
\fn template<typename T> T QVariant::qvariant_cast(QVariant &&value)
\overload
\since 6.7
Returns the given \a value converted to the template type \c{T}.
*/
/*! \fn template<typename T> T qVariantValue(const QVariant &value)
\relates QVariant
\deprecated

View File

@ -606,8 +606,7 @@ QT_BEGIN_NAMESPACE
/*!
\fn QAnyStringView::operator<<(QDebug d, QAnyStringView s)
\since 6.7
\relates QAnyStringView
\relatesalso QDebug
\relates QDebug
Outputs \a s to debug stream \a d.

View File

@ -1380,7 +1380,8 @@ Q_DECL_COLD_FUNCTION static void badSeparatorWarning(const char *method, char se
"language_territory", where language is a lowercase, two-letter ISO 639
language code, and territory is an uppercase, two- or three-letter ISO 3166
territory code. If the locale has no specified territory, only the language
name is returned.
name is returned. An optional \a separator parameter overrides the default
underscore character separating the two tags.
Even if the QLocale object was constructed with an explicit script, name()
will not contain it for compatibility reasons. Use \l bcp47Name() instead if

View File

@ -1359,7 +1359,7 @@
\endlist
\sa QAtomicInteger
\sa QAtomicInteger, qYieldCpu()
*/
/*!

View File

@ -7,7 +7,7 @@
\inmodule QtCore
\ingroup thread
\relates QAtomicInteger
\relatesalso QAtomicPointer
//! \relatesalso QAtomicPointer
\since 6.7
Pauses the execution of the current thread for an unspecified time, using

View File

@ -1284,7 +1284,7 @@ QRhiRenderTarget *QRhiWidget::renderTarget() const
}
/*!
\fn void QRhiWidget::framePresented()
\fn void QRhiWidget::frameSubmitted()
This signal is emitted after the widget's top-level window has finished
composition and has \l{QRhi::endFrame()}{submitted a frame}.