From 239982901beaf039c25b264a9c6b63aa6fe70710 Mon Sep 17 00:00:00 2001 From: Topi Reinio Date: Sat, 1 Aug 2020 00:33:49 +0200 Subject: Doc: Fix documentation warnings for Qt GUI * Drop deprecation warnings for now-dropped items * Use the 'qt6' define and a new \nothing doc macro to conditionally document items on Qt 6 * Add a custom module header for docs that pulls in also Vulkan headers * Add \internal command for internal classes/functions * Move QtGUI-related code snippets from widgets to gui docs Change-Id: Ieb386b96631a49568d09059906d307c45c01d93a Reviewed-by: Paul Wicking --- src/gui/painting/qcolor.cpp | 4 ++++ src/gui/painting/qpaintengine_raster.cpp | 4 ++-- src/gui/painting/qrangecollection.cpp | 10 +++++++--- 3 files changed, 13 insertions(+), 5 deletions(-) (limited to 'src/gui/painting') diff --git a/src/gui/painting/qcolor.cpp b/src/gui/painting/qcolor.cpp index 6b666435e6..89a75d8b2b 100644 --- a/src/gui/painting/qcolor.cpp +++ b/src/gui/painting/qcolor.cpp @@ -843,11 +843,15 @@ QColor::QColor(Spec spec) noexcept #if QT_VERSION < QT_VERSION_CHECK(6,0,0) /*! +\if !defined(qt6) \fn QColor::QColor(const QColor &color) Constructs a color that is a copy of \a color. \sa isValid() +\else + \nothing +\endif */ #endif diff --git a/src/gui/painting/qpaintengine_raster.cpp b/src/gui/painting/qpaintengine_raster.cpp index 5c21f22df1..f34b4bb9a2 100644 --- a/src/gui/painting/qpaintengine_raster.cpp +++ b/src/gui/painting/qpaintengine_raster.cpp @@ -339,7 +339,7 @@ QRasterPaintEnginePrivate::QRasterPaintEnginePrivate() : \sa QPaintEngine */ -/*! +/* \fn QPaintEngine::Type QRasterPaintEngine::type() const \reimp */ @@ -4909,7 +4909,7 @@ static void drawEllipse_midpoint_i(const QRect &rect, const QRect &clip, } } -/*! +/* \fn void QRasterPaintEngine::drawPoints(const QPoint *points, int pointCount) \overload \reimp diff --git a/src/gui/painting/qrangecollection.cpp b/src/gui/painting/qrangecollection.cpp index 5fd4ebaa4b..8f212a1b08 100644 --- a/src/gui/painting/qrangecollection.cpp +++ b/src/gui/painting/qrangecollection.cpp @@ -96,7 +96,7 @@ QRangeCollection::~QRangeCollection() } /*! - Inserts a single number into the collection. + Inserts a single number \a pageNumber into the collection. */ void QRangeCollection::addPage(int pageNumber) { @@ -110,7 +110,7 @@ void QRangeCollection::addPage(int pageNumber) } /*! - Inserts a range into the collection. + Inserts a range specified with \a from and \a to into the collection. */ void QRangeCollection::addRange(int from, int to) { @@ -146,12 +146,14 @@ void QRangeCollection::clear() } /*! - Constructs the range collection from a string representation. + Constructs the range collection from a string representation of \a ranges. \code QPrinter printer; printer->rangeCollection()->parse("1-3,6-7"); \endcode + + Returns \c true on success. */ bool QRangeCollection::parse(const QString &ranges) { @@ -233,6 +235,8 @@ QString QRangeCollection::toString() const } /*! + \fn bool QRangeCollection::contains(const int pageNumber) const + Returns \c true if the collection contains an occurrence or a bounding range of \a pageNumber; otherwise returns \c false. -- cgit v1.2.3