From 234b36698ebff31e3d93acae5e4aa7f73e24664f Mon Sep 17 00:00:00 2001 From: David Boddie Date: Wed, 11 May 2011 14:19:37 +0200 Subject: Doc: Fixed qdoc warnings. --- src/corelib/tools/qstringbuilder.cpp | 3 +- src/corelib/tools/qstringlist.cpp | 2 +- src/gui/graphicsview/qgraphicslayout.cpp | 6 +-- src/gui/image/qimage.cpp | 7 +-- src/gui/itemviews/qtableview.cpp | 2 +- src/gui/kernel/qactiongroup.cpp | 4 +- src/gui/kernel/qapplication_mac.mm | 2 - src/gui/kernel/qapplication_qpa.cpp | 3 ++ src/gui/kernel/qevent.cpp | 6 +-- src/gui/kernel/qgenericplugin_qpa.cpp | 2 +- src/gui/kernel/qgenericpluginfactory_qpa.cpp | 3 +- src/gui/kernel/qplatformcursor_qpa.cpp | 70 ++++++++++++---------------- src/gui/kernel/qplatformglcontext_qpa.cpp | 6 +-- src/gui/kernel/qplatformintegration_qpa.cpp | 16 +++---- src/gui/kernel/qplatformscreen_qpa.cpp | 8 ++-- src/gui/painting/qbrush.cpp | 18 ++++--- src/gui/painting/qpaintengine.cpp | 1 + src/gui/text/qfontdatabase_qws.cpp | 3 -- src/gui/text/qfontmetrics.cpp | 6 ++- src/gui/text/qplatformfontdatabase_qpa.cpp | 26 +++++++---- src/gui/text/qrawfont.cpp | 56 +++++++++++++--------- src/gui/text/qtextdocument.cpp | 2 +- src/gui/text/qtextformat.cpp | 61 +++++++++++++++++------- src/gui/text/qtextlayout.cpp | 10 ++-- src/gui/widgets/qmdiarea.cpp | 2 +- src/gui/widgets/qtabwidget.cpp | 2 +- src/network/access/qhttpmultipart.cpp | 2 +- src/network/ssl/qsslsocket.cpp | 4 +- src/opengl/qgl_qpa.cpp | 4 ++ src/opengl/qgl_x11.cpp | 4 -- src/opengl/qglframebufferobject.cpp | 9 ++-- src/opengl/qglpixelbuffer.cpp | 2 +- 32 files changed, 194 insertions(+), 158 deletions(-) (limited to 'src') diff --git a/src/corelib/tools/qstringbuilder.cpp b/src/corelib/tools/qstringbuilder.cpp index 8c745fc4b7..f249c526cd 100644 --- a/src/corelib/tools/qstringbuilder.cpp +++ b/src/corelib/tools/qstringbuilder.cpp @@ -142,7 +142,8 @@ QT_BEGIN_NAMESPACE characters. */ -/*! \fn operator QStringBuilder::QString() const +/*! + \fn operator QStringBuilder::QString() const Converts the \c QLatin1Literal into a \c QString object. */ diff --git a/src/corelib/tools/qstringlist.cpp b/src/corelib/tools/qstringlist.cpp index 21269a8e7b..eac61f5376 100644 --- a/src/corelib/tools/qstringlist.cpp +++ b/src/corelib/tools/qstringlist.cpp @@ -683,7 +683,7 @@ int QtPrivate::QStringList_removeDuplicates(QStringList *that) /*! \fn QStringList::QStringList(std::initializer_list args) \since 4.8 - Construct a list from a std::initilizer_list. + Construct a list from a std::initializer_list given by \a args. This constructor is only enabled if the compiler supports C++0x */ diff --git a/src/gui/graphicsview/qgraphicslayout.cpp b/src/gui/graphicsview/qgraphicslayout.cpp index a67ae48cc7..ce4452f6e2 100644 --- a/src/gui/graphicsview/qgraphicslayout.cpp +++ b/src/gui/graphicsview/qgraphicslayout.cpp @@ -478,7 +478,7 @@ static bool g_instantInvalidatePropagation = false; /*! \internal \since 4.8 - \see instantInvalidatePropagation + \sa instantInvalidatePropagation() Calling this function with \a enable set to true will enable a feature that makes propagation of invalidation up to ancestor layout items to be done in @@ -489,7 +489,7 @@ static bool g_instantInvalidatePropagation = false; invalid (not activated). This is the recommended behaviour. If not set it will also propagate up the parentLayoutItem() hierarchy, but - it will stop at the \i first \i widget it encounters, and post a layout + it will stop at the \e{first widget} it encounters, and post a layout request to the widget. When the layout request is consumed, this might cause it to continue propagation up to the parentLayoutItem() of the widget. It will continue in this fashion until it has reached a widget with @@ -508,7 +508,7 @@ void QGraphicsLayout::setInstantInvalidatePropagation(bool enable) /*! \internal \since 4.8 - \see setInstantInvalidatePropagation + \sa setInstantInvalidatePropagation() returns true if the complete widget/layout hierarchy is rearranged in one go. */ diff --git a/src/gui/image/qimage.cpp b/src/gui/image/qimage.cpp index 25f6295b71..552a8c081c 100644 --- a/src/gui/image/qimage.cpp +++ b/src/gui/image/qimage.cpp @@ -2008,10 +2008,11 @@ void QImage::fill(uint pixel) /*! \fn void QImage::fill(Qt::GlobalColor color) - \overload - \since 4.8 + + Fills the image with the given \a color, described as a standard global + color. */ void QImage::fill(Qt::GlobalColor color) @@ -2022,7 +2023,7 @@ void QImage::fill(Qt::GlobalColor color) /*! - \fn void QImage::fill(Qt::GlobalColor color) + \fn void QImage::fill(const QColor &color) \overload diff --git a/src/gui/itemviews/qtableview.cpp b/src/gui/itemviews/qtableview.cpp index e70f3569aa..f9e991934a 100644 --- a/src/gui/itemviews/qtableview.cpp +++ b/src/gui/itemviews/qtableview.cpp @@ -1102,7 +1102,7 @@ void QTableView::setRootIndex(const QModelIndex &index) } /*! - \reimp + \internal */ void QTableView::doItemsLayout() { diff --git a/src/gui/kernel/qactiongroup.cpp b/src/gui/kernel/qactiongroup.cpp index 95ea8afab7..20787e4f47 100644 --- a/src/gui/kernel/qactiongroup.cpp +++ b/src/gui/kernel/qactiongroup.cpp @@ -108,8 +108,8 @@ void QActionGroupPrivate::_q_actionHovered() \ingroup mainwindow-classes - In some situations it is useful to group actions together. For - example, if you have a \gui{Left Align} action, a \gui{Right + In some situations it is useful to group QAction objects together. + For example, if you have a \gui{Left Align} action, a \gui{Right Align} action, a \gui{Justify} action, and a \gui{Center} action, only one of these actions should be active at any one time. One simple way of achieving this is to group the actions together in diff --git a/src/gui/kernel/qapplication_mac.mm b/src/gui/kernel/qapplication_mac.mm index f607a72e92..c0c97e9426 100644 --- a/src/gui/kernel/qapplication_mac.mm +++ b/src/gui/kernel/qapplication_mac.mm @@ -2623,8 +2623,6 @@ OSStatus QApplicationPrivate::globalAppleEventProcessor(const AppleEvent *ae, Ap Return true if you want to stop the event from being processed. Return false for normal event dispatching. The default implementation returns false. - - \sa macEventFilter(void *nsevent) */ bool QApplication::macEventFilter(EventHandlerCallRef, EventRef) { diff --git a/src/gui/kernel/qapplication_qpa.cpp b/src/gui/kernel/qapplication_qpa.cpp index b754cf7de8..8441355150 100644 --- a/src/gui/kernel/qapplication_qpa.cpp +++ b/src/gui/kernel/qapplication_qpa.cpp @@ -444,6 +444,9 @@ void QApplication::alert(QWidget *, int) { } +/*! + \internal +*/ QPlatformNativeInterface *QApplication::platformNativeInterface() { QPlatformIntegration *pi = QApplicationPrivate::platformIntegration(); diff --git a/src/gui/kernel/qevent.cpp b/src/gui/kernel/qevent.cpp index 277a5e845d..910b43a997 100644 --- a/src/gui/kernel/qevent.cpp +++ b/src/gui/kernel/qevent.cpp @@ -3103,10 +3103,10 @@ QUrl QFileOpenEvent::url() const } /*! - \fn bool openFile(QFile &file, QIODevice::OpenMode flags) const + \fn bool QFileOpenEvent::openFile(QFile &file, QIODevice::OpenMode flags) const - Opens a QFile on the file referenced by this event. - Returns true if successful; otherwise returns false. + Opens a QFile on the \a file referenced by this event in the mode specified + by \a flags. Returns true if successful; otherwise returns false. This is necessary as some files cannot be opened by name, but require specific information stored in this event. diff --git a/src/gui/kernel/qgenericplugin_qpa.cpp b/src/gui/kernel/qgenericplugin_qpa.cpp index 43d6525bb6..17453f3d32 100644 --- a/src/gui/kernel/qgenericplugin_qpa.cpp +++ b/src/gui/kernel/qgenericplugin_qpa.cpp @@ -53,7 +53,7 @@ QT_BEGIN_NAMESPACE \brief The QGenericPlugin class is an abstract base class for window-system related plugins in Qt QPA. - Note that this class is only available in \l{Qt QPA}. + Note that this class is only available in Qt QPA. A mouse plugin can be created by subclassing QGenericPlugin and reimplementing the pure virtual keys() and diff --git a/src/gui/kernel/qgenericpluginfactory_qpa.cpp b/src/gui/kernel/qgenericpluginfactory_qpa.cpp index abc575ae86..c77ea1152a 100644 --- a/src/gui/kernel/qgenericpluginfactory_qpa.cpp +++ b/src/gui/kernel/qgenericpluginfactory_qpa.cpp @@ -65,8 +65,7 @@ Q_GLOBAL_STATIC_WITH_ARGS(QFactoryLoader, loader, \brief The QGenericPluginFactory class creates window-system related plugin drivers in Qt QPA. - Note that this class is only available in \l{Qt QPA}. - + Note that this class is only available in Qt QPA. \sa QGenericPlugin */ diff --git a/src/gui/kernel/qplatformcursor_qpa.cpp b/src/gui/kernel/qplatformcursor_qpa.cpp index 2ea8332ecc..f430f6edf1 100644 --- a/src/gui/kernel/qplatformcursor_qpa.cpp +++ b/src/gui/kernel/qplatformcursor_qpa.cpp @@ -52,48 +52,46 @@ QT_BEGIN_NAMESPACE QList > QPlatformCursorPrivate::instances; /*! - \class QGraphicsSystemCursor + \class QPlatformCursor - \brief The QGraphicsSystemCursor class provides information about + \brief The QPlatformCursor class provides information about pointer device events (movement, buttons), and requests to change the currently displayed cursor. - Note that QGraphicsSystemCursor does not include any graphics for + Note that QPlatformCursor does not include any graphics for display. An application that sets a QCursor may provide its own graphics. - \sa QGraphicsSystemCursorImage + \sa QPlatformCursorImage */ /*! - \fn virtual void QGraphicsSystemCursor::pointerEvent(const QMouseEvent & event) + \fn virtual void QPlatformCursor::pointerEvent(const QMouseEvent & event) This method is called by Qt whenever a QMouseEvent is generated by the underlying pointer input. \a event is a reference to the QMouseEvent in question. A default do-nothing implementation is provided. - - \sa QApplicationPrivate::handleMouseEvent() */ /*! - \fn virtual void QGraphicsSystemCursor::changeCursor(QCursor * widgetCursor, QWidget * widget) + \fn virtual void QPlatformCursor::changeCursor(QCursor * widgetCursor, QWidget * widget) \brief This method is called by Qt whenever the cursor graphic should be changed. - Implementation of this method is mandatory for a subclass of QGraphicsSystemCursor. + Implementation of this method is mandatory for a subclass of QPlatformCursor. \a widgetCursor is a pointer to the QCursor that should be displayed. \a widget is a pointer to the widget currently displayed at QCursor::pos(). Note that this may be 0 if the current position is not occupied by a displayed widget. - \sa QApplicationPrivate::handleMouseEvent(), QCursor::pos() + \sa QCursor::pos() */ /*! - \fn QGraphicsSystemCursor::QGraphicsSystemCursor() + \fn QPlatformCursor::QPlatformCursor() - \brief Constructs a QGraphicsSystemCursor + \brief Constructs a QPlatformCursor */ QPlatformCursor::QPlatformCursor(QPlatformScreen *scr ) : screen(scr) @@ -106,12 +104,12 @@ QPlatformCursor::QPlatformCursor(QPlatformScreen *scr ) // from src/gui/embedded/QGraphicsSystemCursorImage_qws.cpp /*! - \class QGraphicsSystemCursorImage + \class QPlatformCursorImage - \brief The QGraphicsSystemCursorImage class provides a set of graphics + \brief The QPlatformCursorImage class provides a set of graphics intended to be used as cursors. - \sa QGraphicsSystemCursor + \sa QPlatformCursor */ static QPlatformCursorImage *systemCursorTable[Qt::LastCursor+1]; @@ -502,7 +500,7 @@ void QPlatformCursorImage::createSystemCursor(int id) } /*! - \fn void QGraphicsSystemCursorImage::set(Qt::CursorShape id) + \fn void QPlatformCursorImage::set(Qt::CursorShape id) \brief Calling this method sets the cursor image to the specified shape @@ -531,15 +529,8 @@ void QPlatformCursorImage::set(Qt::CursorShape id) } /*! - \fn void QGraphicsSystemCursorImage::set(const QImage * image, int hx, int hy) - - \brief Set the cursor image to the specified QImage, with the hotsport at (hx, hy) - - \a image A pointer to a QImage - - \a hx The x coordinate of the cursor's hotspot - - \a hy the y coordinate of the cursor's hotspot + Sets the cursor image to the given \a image, with the hotspot at the + point specified by (\a hx, \a hy). */ void QPlatformCursorImage::set(const QImage &image, int hx, int hy) @@ -550,22 +541,19 @@ void QPlatformCursorImage::set(const QImage &image, int hx, int hy) } /*! - \fn void QGraphicsSystemCursorImage::set(const uchar *data, const uchar *mask, int width, int height, int hx, int hy) - - \brief set the cursor image to the graphic represented by the combination of data, mask, - width, and height + \fn void QPlatformCursorImage::set(const uchar *data, const uchar *mask, int width, int height, int hx, int hy) - \a data The pixel data of the graphic - - \a mask Mask data for the graphic. pixels in data with a corresponding mask bit of 0 are not drawn - - \a width The width of the graphic in pixels - - \a height The height of the graphic in pixels + Sets the cursor image to the graphic represented by the combination of + \a data and \a mask, with dimensions given by \a width and \a height and a + hotspot at the point specified by (\a hx, \a hy). - \a hx The X hotspot of the cursor graphic + The image data specified by \a data must be supplied in the format + described by QImage::Format_Indexed8. - \a hy The Y hotspot of the cursor graphic + The corresponding mask data specified by \a mask must be supplied in a + character array containing packed 1 bit per pixel format data, with any + padding bits at the end of the array. Bits of value 0 represent transparent + pixels in the image data. */ void QPlatformCursorImage::set(const uchar *data, const uchar *mask, int width, int height, int hx, int hy) @@ -625,7 +613,7 @@ void QPlatformCursorImage::set(const uchar *data, const uchar *mask, } /*! - \fn QGraphicsSystemCursorImage::QGraphicsSystemCursorImage(const uchar *data, const uchar *mask, int width, int height, int hotX, int hotY) + \fn QPlatformCursorImage::QPlatformCursorImage(const uchar *data, const uchar *mask, int width, int height, int hotX, int hotY) \brief set the cursor image to the graphic represented by the combination of data, mask, width, and height @@ -646,13 +634,13 @@ void QPlatformCursorImage::set(const uchar *data, const uchar *mask, */ /*! - \fn QImage *QGraphicsSystemCursorImage::image() + \fn QImage *QPlatformCursorImage::image() \brief Return the cursor graphic as a pointer to a QImage */ /*! - \fn QPoint QGraphicsSystemCursorImage::hotspot() + \fn QPoint QPlatformCursorImage::hotspot() \brief Return the cursor's hotspot */ diff --git a/src/gui/kernel/qplatformglcontext_qpa.cpp b/src/gui/kernel/qplatformglcontext_qpa.cpp index 181053223f..918b41be1c 100644 --- a/src/gui/kernel/qplatformglcontext_qpa.cpp +++ b/src/gui/kernel/qplatformglcontext_qpa.cpp @@ -191,17 +191,17 @@ void QPlatformGLContext::deleteQGLContext() which maps to the QPlatformGLContext. */ -/*! \fn void swapBuffers() +/*! \fn void QPlatformGLContext::swapBuffers() Reimplement in subclass to native swap buffers calls */ -/*! getProcAddress(const QString& procName) +/*! \fn void *QPlatformGLContext::getProcAddress(const QString &procName) Reimplement in subclass to native getProcAddr calls. Note: its convenient to use qPrintable(const QString &str) to get the const char * pointer */ -/*! platformWindowFormat() const +/*! \fn QPlatformWindowFormat QPlatformGLContext::platformWindowFormat() const QWidget has the function qplatformWindowFormat(). That function is for the application programmer to request the format of the window and the context that he wants. diff --git a/src/gui/kernel/qplatformintegration_qpa.cpp b/src/gui/kernel/qplatformintegration_qpa.cpp index 8ff12ebf9c..fa12518efa 100644 --- a/src/gui/kernel/qplatformintegration_qpa.cpp +++ b/src/gui/kernel/qplatformintegration_qpa.cpp @@ -132,20 +132,20 @@ QPlatformNativeInterface * QPlatformIntegration::nativeInterface() const the recommended approach for making new platform plugin is to copy an existing plugin inside the QTSRCTREE/src/plugins/platform and develop the plugin inside the source tree. - The minimal platformintegration is the smallest platform integration it is possible to make, + The minimal platform integration is the smallest platform integration it is possible to make, which makes it an ideal starting point for new plugins. For a slightly more advanced plugin, consider reviewing the directfb plugin, or the testlite plugin. */ /*! - \fn QPixmapData *createPixmapData(QPixmapData::PixelType type) const + \fn QPixmapData *QPlatformIntegration::createPixmapData(QPixmapData::PixelType type) const Factory function for QPixmapData. PixelType can be either PixmapType or BitmapType. \sa QPixmapData */ /*! - \fn QPlatformWindow *createPlatformWindow(QWidget *widget, WId winId = 0) const + \fn QPlatformWindow *QPlatformIntegration::createPlatformWindow(QWidget *widget, WId winId = 0) const Factory function for QPlatformWindow. The widget parameter is a pointer to the top level widget(tlw) which the QPlatformWindow is suppose to be created for. The WId handle is actually @@ -162,7 +162,7 @@ QPlatformNativeInterface * QPlatformIntegration::nativeInterface() const */ /*! - \fn QWindowSurface *createWindowSurface(QWidget *widget, WId winId) const + \fn QWindowSurface *QPlatformIntegration::createWindowSurface(QWidget *widget, WId winId) const Factory function for QWindowSurface. The QWidget parameter is a pointer to the top level widget(tlw) the window surface is created for. A QPlatformWindow is always created @@ -175,7 +175,7 @@ QPlatformNativeInterface * QPlatformIntegration::nativeInterface() const */ /*! - \fn void moveToScreen(QWidget *window, int screen) + \fn void QPlatformIntegration::moveToScreen(QWidget *window, int screen) This function is called when a QWidget is displayed on screen, or the QWidget is to be displayed on a new screen. The QWidget parameter is a pointer to the top level widget and @@ -187,14 +187,14 @@ QPlatformNativeInterface * QPlatformIntegration::nativeInterface() const */ /*! - \fn QList screens() const + \fn QList QPlatformIntegration::screens() const Accessor function to a list of all the screens on the current system. The screen with the index == 0 is the default/main screen. */ /*! - \fn bool isVirtualDesktop() + \fn bool QPlatformIntegration::isVirtualDesktop() Returns if the current windowing system configuration defines all the screens to be one desktop(virtual desktop), or if each screen is a desktop of its own. @@ -203,7 +203,7 @@ QPlatformNativeInterface * QPlatformIntegration::nativeInterface() const */ /*! - \fn QPixmap grabWindow(WId window, int x, int y, int width, int height) const + \fn QPixmap QPlatformIntegration::grabWindow(WId window, int x, int y, int width, int height) const This function is called when Qt needs to be able to grab the content of a window. diff --git a/src/gui/kernel/qplatformscreen_qpa.cpp b/src/gui/kernel/qplatformscreen_qpa.cpp index c9f3dc6f34..5e3c453f92 100644 --- a/src/gui/kernel/qplatformscreen_qpa.cpp +++ b/src/gui/kernel/qplatformscreen_qpa.cpp @@ -110,20 +110,20 @@ QPlatformScreen * QPlatformScreen::platformScreenForWidget(const QWidget *widget QPlatformScreen is also used by the public api QDesktopWidget for information about the desktop. */ -/*! \fn geometry() const +/*! \fn QRect QPlatformScreen::geometry() const = 0 Reimplement in subclass to return the pixel geometry of the screen */ -/*! \fn availableGeometry() const +/*! \fn QRect QPlatformScreen::availableGeometry() const Reimplement in subclass to return the pixel geometry of the available space This normally is the desktop screen minus the task manager, global menubar etc. */ -/*! \fn depth() const +/*! \fn int QPlatformScreen::depth() const = 0 Reimplement in subclass to return current depth of the screen */ -/*! \fn format() const +/*! \fn QImage::Format QPlatformScreen::format() const = 0 Reimplement in subclass to return the image format which corresponds to the screen format */ diff --git a/src/gui/painting/qbrush.cpp b/src/gui/painting/qbrush.cpp index 3ff7eb84d0..60297e6b02 100644 --- a/src/gui/painting/qbrush.cpp +++ b/src/gui/painting/qbrush.cpp @@ -1826,9 +1826,9 @@ static QPointF qt_radial_gradient_adapt_focal_point(const QPointF ¢er, radius and \a focalPoint. \note If the given focal point is outside the circle defined by the - center (\a cx, \a cy) and the \a radius it will be re-adjusted to - the intersection between the line from the center to the focal point - and the circle. + \a center point and \a radius, it will be re-adjusted to lie at a point on + the circle where it intersects with the line from \a center to + \a focalPoint. \sa QGradient::setColorAt(), QGradient::setStops() */ @@ -1947,11 +1947,9 @@ QRadialGradient::QRadialGradient(const QPointF ¢er, qreal centerRadius, cons /*! \since 4.8 - Constructs an extended radial gradient with the given \a center, \a - centerRadius, \a focalPoint, and \a focalRadius. - Constructs a radial gradient with the given center (\a cx, \a cy), - center radius \a centerRadius, focal point (\a fx, \a fy), and - focal radius \a focalRadius. + Constructs an extended radial gradient with the given center + (\a cx, \a cy), center radius, \a centerRadius, focal point, (\a fx, \a fy), + and focal radius \a focalRadius. */ QRadialGradient::QRadialGradient(qreal cx, qreal cy, qreal centerRadius, qreal fx, qreal fy, qreal focalRadius) { @@ -2049,7 +2047,7 @@ qreal QRadialGradient::centerRadius() const return m_data.radial.cradius; } -/* +/*! \since 4.8 Sets the center radius of this radial gradient in logical coordinates @@ -2080,7 +2078,7 @@ qreal QRadialGradient::focalRadius() const return u.f; } -/* +/*! \since 4.8 Sets the focal radius of this radial gradient in logical coordinates diff --git a/src/gui/painting/qpaintengine.cpp b/src/gui/painting/qpaintengine.cpp index 6eb09e5966..35478f8f3b 100644 --- a/src/gui/painting/qpaintengine.cpp +++ b/src/gui/painting/qpaintengine.cpp @@ -387,6 +387,7 @@ void QPaintEngine::drawPolygon(const QPoint *points, int pointCount, PolygonDraw \value MaxUser Last user type ID \value OpenGL2 \value PaintBuffer + \value Blitter */ /*! diff --git a/src/gui/text/qfontdatabase_qws.cpp b/src/gui/text/qfontdatabase_qws.cpp index d076de05d3..321feb4feb 100644 --- a/src/gui/text/qfontdatabase_qws.cpp +++ b/src/gui/text/qfontdatabase_qws.cpp @@ -759,9 +759,6 @@ bool QFontDatabase::supportsThreadedFontRendering() return true; } -/*! - \internal -*/ QFontEngine * QFontDatabase::findFont(int script, const QFontPrivate *fp, const QFontDef &request) diff --git a/src/gui/text/qfontmetrics.cpp b/src/gui/text/qfontmetrics.cpp index 2ec245e5da..39b06e2eac 100644 --- a/src/gui/text/qfontmetrics.cpp +++ b/src/gui/text/qfontmetrics.cpp @@ -1329,8 +1329,10 @@ bool QFontMetricsF::inFont(QChar ch) const } /*! - Returns true if the character encoded in UCS-4/UTF-32 is a valid - character in the font; otherwise returns false. + \fn bool QFontMetricsF::inFontUcs4(uint ch) const + + Returns true if the character given by \a ch, encoded in UCS-4/UTF-32, + is a valid character in the font; otherwise returns false. */ bool QFontMetricsF::inFontUcs4(uint ucs4) const { diff --git a/src/gui/text/qplatformfontdatabase_qpa.cpp b/src/gui/text/qplatformfontdatabase_qpa.cpp index 82ec2793b9..ea115c44d0 100644 --- a/src/gui/text/qplatformfontdatabase_qpa.cpp +++ b/src/gui/text/qplatformfontdatabase_qpa.cpp @@ -206,7 +206,8 @@ void QPlatformFontDatabase::populateFontDatabase() } /*! - + Returns the font engine that can be used to render the font described by + the font definition, \a fontDef, in the specified \a script. */ QFontEngine *QPlatformFontDatabase::fontEngine(const QFontDef &fontDef, QUnicodeTables::Script script, void *handle) { @@ -229,7 +230,8 @@ QFontEngine *QPlatformFontDatabase::fontEngine(const QByteArray &fontData, qreal } /*! - + Returns a list of alternative fonts for the specified \a family and + \a style and \a script using the \a styleHint given. */ QStringList QPlatformFontDatabase::fallbacksForFamily(const QString family, const QFont::Style &style, const QFont::StyleHint &styleHint, const QUnicodeTables::Script &script) const { @@ -241,7 +243,9 @@ QStringList QPlatformFontDatabase::fallbacksForFamily(const QString family, cons } /*! - Adds an application font. Returns a list of family names, or an empty list if the font could + Adds an application font described by the given \a fontData that can be + referenced using the specified \a fontName, which is the name for the font + family. Returns a list of family names, or an empty list if the font could not be added */ QStringList QPlatformFontDatabase::addApplicationFont(const QByteArray &fontData, const QString &fileName) @@ -280,21 +284,23 @@ QString QPlatformFontDatabase::fontDir() const /*! \class QPlatformFontDatabase - \brief The QPlatformFontDatabase makes it possible to customize how fonts are picked up, and - and how they are rendered + \brief The QPlatformFontDatabase class makes it possible to customize how fonts + are discovered and how they are rendered \ingroup painting QPlatformFontDatabase is the superclass which is intended to let platform implementations use native font handling. - Qt has its internal fontdatabase which it uses to pick up available fonts. To be able - to populate this database subclass this class, and reimplement populateFontDatabase(). + Qt has its internal font database which it uses to discover available fonts on the + user's system. To be able to populate this database subclass this class, and + reimplement populateFontDatabase(). - Use the function registerFont to populate the internal fontdatabase. + Use the function registerFont() to populate the internal font database. - Sometimes a specified font does not have the required glyphs, then the fallbackForFamily - function is called. + Sometimes a specified font does not have the required glyphs; in such a case, the + fallbackForFamily() function is called automatically to find alternative font + families that can supply alternatives to the missing glyphs. \sa QSupportedWritingSystems */ diff --git a/src/gui/text/qrawfont.cpp b/src/gui/text/qrawfont.cpp index 1c7d5ad4b6..8b8b700847 100644 --- a/src/gui/text/qrawfont.cpp +++ b/src/gui/text/qrawfont.cpp @@ -87,16 +87,16 @@ QT_BEGIN_NAMESPACE QRawFont can be constructed in a number of ways: \list - \o \l It can be constructed by calling QTextLayout::glyphRuns() or QTextFragment::glyphRuns(). - The returned QGlyphRun objects will contain QRawFont objects which represent the actual - fonts used to render each portion of the text. - \o \l It can be constructed by passing a QFont object to QRawFont::fromFont(). The function - will return a QRawFont object representing the font that will be selected as response to - the QFont query and the selected writing system. - \o \l It can be constructed by passing a file name or QByteArray directly to the QRawFont - constructor, or by calling loadFromFile() or loadFromData(). In this case, the - font will not be registered in QFontDatabase, and it will not be available as part of - regular font selection. + \o It can be constructed by calling QTextLayout::glyphs() or QTextFragment::glyphs(). The + returned QGlyphs objects will contain QRawFont objects which represent the actual fonts + used to render each portion of the text. + \o It can be constructed by passing a QFont object to QRawFont::fromFont(). The function + will return a QRawFont object representing the font that will be selected as response to + the QFont query and the selected writing system. + \o It can be constructed by passing a file name or QByteArray directly to the QRawFont + constructor, or by calling loadFromFile() or loadFromData(). In this case, the + font will not be registered in QFontDatabase, and it will not be available as part of + regular font selection. \endlist QRawFont is considered local to the thread in which it is constructed (either using a @@ -132,8 +132,9 @@ QRawFont::QRawFont() } /*! - Constructs a QRawFont representing the font contained in the file referenced by \a fileName, - with \a pixelSize size in pixels, and the selected \a hintingPreference. + Constructs a QRawFont representing the font contained in the file referenced + by \a fileName for the size (in pixels) given by \a pixelSize, and using the + hinting preference specified by \a hintingPreference. \note The referenced file must contain a TrueType or OpenType font. */ @@ -146,7 +147,9 @@ QRawFont::QRawFont(const QString &fileName, } /*! - Constructs a QRawFont representing the font contained in \a fontData. + Constructs a QRawFont representing the font contained in the supplied + \a fontData for the size (in pixels) given by \a pixelSize, and using the + hinting preference specified by \a hintingPreference. \note The data must contain a TrueType or OpenType font. */ @@ -192,7 +195,9 @@ bool QRawFont::isValid() const } /*! - Replaces the current QRawFont with the contents of the file references by \a fileName. + Replaces the current QRawFont with the contents of the file referenced + by \a fileName for the size (in pixels) given by \a pixelSize, and using the + hinting preference specified by \a hintingPreference. The file must reference a TrueType or OpenType font. @@ -208,7 +213,9 @@ void QRawFont::loadFromFile(const QString &fileName, } /*! - Replaces the current QRawFont with the contents of \a fontData. + Replaces the current QRawFont with the font contained in the supplied + \a fontData for the size (in pixels) given by \a pixelSize, and using the + hinting preference specified by \a hintingPreference. The \a fontData must contain a TrueType or OpenType font. @@ -226,8 +233,9 @@ void QRawFont::loadFromData(const QByteArray &fontData, } /*! - This function returns a rasterized image of the glyph at a given \a glyphIndex in the underlying - font, if the QRawFont is valid, otherwise it will return an invalid QImage. + This function returns a rasterized image of the glyph at the given + \a glyphIndex in the underlying font, using the \a transform specified. + If the QRawFont is not valid, this function will return an invalid QImage. If \a antialiasingType is set to QRawFont::SubPixelAntialiasing, then the resulting image will be in QImage::Format_RGB32 and the RGB values of each pixel will represent the subpixel opacities of @@ -422,11 +430,15 @@ int QRawFont::weight() const } /*! - Converts a string of unicode points to glyph indexes using the CMAP table in the - underlying font. Note that in cases where there are other tables in the font that affect the - shaping of the text, the returned glyph indexes will not correctly represent the rendering - of the text. To get the correctly shaped text, you can use QTextLayout to lay out and shape the - text, and then call QTextLayout::glyphRuns() to get the set of glyph index list and QRawFont pairs. + Converts the string of unicode points given by \a text to glyph indexes + using the CMAP table in the underlying font, and returns a vector containing + the result. + + Note that, in cases where there are other tables in the font that affect the + shaping of the text, the returned glyph indexes will not correctly represent + the rendering of the text. To get the correctly shaped text, you can use + QTextLayout to lay out and shape the text, then call QTextLayout::glyphs() + to get the set of glyph index list and QRawFont pairs. \sa advancesForGlyphIndexes(), glyphIndexesForChars(), QGlyphRun, QTextLayout::glyphRuns(), QTextFragment::glyphRuns() */ diff --git a/src/gui/text/qtextdocument.cpp b/src/gui/text/qtextdocument.cpp index 0d33912420..851a050151 100644 --- a/src/gui/text/qtextdocument.cpp +++ b/src/gui/text/qtextdocument.cpp @@ -600,7 +600,7 @@ Qt::CursorMoveStyle QTextDocument::defaultCursorMoveStyle() const /*! \since 4.8 - Set the default cursor movement style. + Sets the default cursor movement style to the given \a style. */ void QTextDocument::setDefaultCursorMoveStyle(Qt::CursorMoveStyle style) { diff --git a/src/gui/text/qtextformat.cpp b/src/gui/text/qtextformat.cpp index a02ea49f67..d0c89d8203 100644 --- a/src/gui/text/qtextformat.cpp +++ b/src/gui/text/qtextformat.cpp @@ -571,6 +571,8 @@ Q_GUI_EXPORT QDataStream &operator>>(QDataStream &stream, QTextFormat &fmt) \value FontStyleHint Corresponds to the QFont::StyleHint property \value FontStyleStrategy Corresponds to the QFont::StyleStrategy property \value FontKerning Specifies whether the font has kerning turned on. + \value FontHintingPreference Controls the use of hinting according to values + of the QFont::HintingPreference enum. \omitvalue FirstFontProperty \omitvalue LastFontProperty @@ -588,8 +590,13 @@ Q_GUI_EXPORT QDataStream &operator>>(QDataStream &stream, QTextFormat &fmt) List properties - \value ListStyle - \value ListIndent + \value ListStyle Specifies the style used for the items in a list, + described by values of the QTextListFormat::Style enum. + \value ListIndent Specifies the amount of indentation used for a list. + \value ListNumberPrefix Defines the text which is prepended to item numbers in + numeric lists. + \value ListNumberSuffix Defines the text which is appended to item numbers in + numeric lists. Table and frame properties @@ -1263,16 +1270,18 @@ bool QTextFormat::operator==(const QTextFormat &rhs) const \value AlignNormal Adjacent characters are positioned in the standard way for text in the writing system in use. - \value AlignSuperScript Characters are placed above the baseline for + \value AlignSuperScript Characters are placed above the base line for normal text. - \value AlignSubScript Characters are placed below the baseline for + \value AlignSubScript Characters are placed below the base line for normal text. - \value AlignMiddle The center of the object is vertically aligned with the base line. - Currently, this is only implemented for inline objects. + \value AlignMiddle The center of the object is vertically aligned with the + base line. Currently, this is only implemented for + inline objects. \value AlignBottom The bottom edge of the object is vertically aligned with the base line. \value AlignTop The top edge of the object is vertically aligned with the base line. + \value AlignBaseline The base lines of the characters are aligned. */ /*! @@ -2136,8 +2145,9 @@ QList QTextBlockFormat::tabPositions() const \fn void QTextBlockFormat::setLineHeight(qreal height, int heightType) \since 4.8 - This sets the line height for the paragraph to the value in height - which is dependant on heightType, described by the LineHeightTypes enum. + Sets the line height for the paragraph to the value given by \a height + which is dependent on \a heightType in the way described by the + LineHeightTypes enum. \sa LineHeightTypes, lineHeight(), lineHeightType() */ @@ -2147,11 +2157,16 @@ QList QTextBlockFormat::tabPositions() const \fn qreal QTextBlockFormat::lineHeight(qreal scriptLineHeight, qreal scaling) const \since 4.8 - This returns what the height of the lines in the paragraph will be depending - on the given height of the script line and the scaling. The value that is returned - is also dependant on the given LineHeightType of the paragraph as well as the LineHeight - setting that has been set for the paragraph. The scaling is needed for the heights - that include a fixed number of pixels, to scale them appropriately for printing. + Returns the height of the lines in the paragraph based on the height of the + script line given by \a scriptLineHeight and the specified \a scaling + factor. + + The value that is returned is also dependent on the given LineHeightType of + the paragraph as well as the LineHeight setting that has been set for the + paragraph. + + The scaling is needed for heights that include a fixed number of pixels, to + scale them appropriately for printing. \sa LineHeightTypes, setLineHeight(), lineHeightType() */ @@ -2237,6 +2252,13 @@ QList QTextBlockFormat::tabPositions() const numbering scheme used for items in the list. Note that lists that use the decimal numbering scheme begin counting at 1 rather than 0. + Style properties can be set to further configure the appearance of list + items; for example, the ListNumberPrefix and ListNumberSuffix properties + can be used to customize the numbers used in an ordered list so that they + appear as (1), (2), (3), etc.: + + \snippet doc/src/snippets/textdocument-listitemstyles/mainwindow.cpp add a styled, ordered list + \sa QTextList */ @@ -2328,8 +2350,11 @@ QTextListFormat::QTextListFormat(const QTextFormat &fmt) \fn void QTextListFormat::setNumberPrefix(const QString &numberPrefix) \since 4.8 - Sets the list format's number prefix. This can be used with all - sorted list types. It does not have any effect on unsorted list types. + Sets the list format's number prefix to the string specified by + \a numberPrefix. This can be used with all sorted list types. It does not + have any effect on unsorted list types. + + The default prefix is an empty string. \sa numberPrefix() */ @@ -2347,8 +2372,10 @@ QTextListFormat::QTextListFormat(const QTextFormat &fmt) \fn void QTextListFormat::setNumberSuffix(const QString &numberSuffix) \since 4.8 - Sets the list format's number suffix. This can be used with all - sorted list types. It does not have any effect on unsorted list types. + Sets the list format's number suffix to the string specified by + \a numberSuffix. This can be used with all sorted list types. It does not + have any effect on unsorted list types. + The default suffix is ".". \sa numberSuffix() diff --git a/src/gui/text/qtextlayout.cpp b/src/gui/text/qtextlayout.cpp index 91809c3266..7ad9328e40 100644 --- a/src/gui/text/qtextlayout.cpp +++ b/src/gui/text/qtextlayout.cpp @@ -579,12 +579,12 @@ bool QTextLayout::cacheEnabled() const } /*! - Set the cursor movement style. If the QTextLayout is backed by - a document, you can ignore this and use the option in QTextDocument, - this option is for widgets like QLineEdit or custom widgets without - a QTextDocument. Default value is Qt::LogicalMoveStyle. + Sets the visual cursor movement style to the given \a style. If the + QTextLayout is backed by a document, you can ignore this and use the option + in QTextDocument, this option is for widgets like QLineEdit or custom + widgets without a QTextDocument. Default value is QTextCursor::Logical. - \sa setCursorMoveStyle() + \sa cursorMoveStyle() */ void QTextLayout::setCursorMoveStyle(Qt::CursorMoveStyle style) { diff --git a/src/gui/widgets/qmdiarea.cpp b/src/gui/widgets/qmdiarea.cpp index 2a486bba18..2e274f2ba2 100644 --- a/src/gui/widgets/qmdiarea.cpp +++ b/src/gui/widgets/qmdiarea.cpp @@ -2176,7 +2176,7 @@ void QMdiArea::setTabsClosable(bool closable) Tabs are not movable by default. - \sa QTabBar::tabsMovable, setViewMode() + \sa QTabBar::movable, setViewMode() */ bool QMdiArea::tabsMovable() const { diff --git a/src/gui/widgets/qtabwidget.cpp b/src/gui/widgets/qtabwidget.cpp index c296b77370..f16205c895 100644 --- a/src/gui/widgets/qtabwidget.cpp +++ b/src/gui/widgets/qtabwidget.cpp @@ -883,7 +883,7 @@ QSize QTabWidget::minimumSizeHint() const .expandedTo(QApplication::globalStrut()); } -/* +/*! \reimp */ int QTabWidget::heightForWidth(int width) const diff --git a/src/network/access/qhttpmultipart.cpp b/src/network/access/qhttpmultipart.cpp index 640f9ead01..07d5988b39 100644 --- a/src/network/access/qhttpmultipart.cpp +++ b/src/network/access/qhttpmultipart.cpp @@ -256,7 +256,7 @@ void QHttpPart::setBodyDevice(QIODevice *device) /*! Constructs a QHttpMultiPart with content type MixedType and sets - parent as the parent object. + \a parent as the parent object. \sa QHttpMultiPart::ContentType */ diff --git a/src/network/ssl/qsslsocket.cpp b/src/network/ssl/qsslsocket.cpp index 2695df1aef..8d39b4c6dd 100644 --- a/src/network/ssl/qsslsocket.cpp +++ b/src/network/ssl/qsslsocket.cpp @@ -675,8 +675,8 @@ QString QSslSocket::peerVerifyName() const /*! \since 4.8 - Sets a different hostname for the certificate validation instead of the one used for the TCP - connection. + Sets a different host name, given by \a hostName, for the certificate + validation instead of the one used for the TCP connection. \sa connectToHostEncrypted() */ diff --git a/src/opengl/qgl_qpa.cpp b/src/opengl/qgl_qpa.cpp index 9da650f98d..0f7829a4c1 100644 --- a/src/opengl/qgl_qpa.cpp +++ b/src/opengl/qgl_qpa.cpp @@ -380,6 +380,10 @@ QGLContext::QGLContext(QPlatformGLContext *platformContext) d->setupSharing(); } +/*! + Returns a OpenGL context for the platform-specific OpenGL context given by + \a platformContext. +*/ QGLContext *QGLContext::fromPlatformGLContext(QPlatformGLContext *platformContext) { if (!platformContext) diff --git a/src/opengl/qgl_x11.cpp b/src/opengl/qgl_x11.cpp index 9b520034f8..9e170adaed 100644 --- a/src/opengl/qgl_x11.cpp +++ b/src/opengl/qgl_x11.cpp @@ -1407,10 +1407,6 @@ bool QGLWidgetPrivate::renderCxPm(QPixmap* pm) return true; } -/*! \internal - Free up any allocated colormaps. This fn is only called for - top-level widgets. -*/ void QGLWidgetPrivate::cleanupColormaps() { if (!cmap.handle()) { diff --git a/src/opengl/qglframebufferobject.cpp b/src/opengl/qglframebufferobject.cpp index 8eda222c8d..d882916425 100644 --- a/src/opengl/qglframebufferobject.cpp +++ b/src/opengl/qglframebufferobject.cpp @@ -205,13 +205,16 @@ int QGLFramebufferObjectFormat::samples() const /*! \since 4.8 - Enables or disables mipmapping. Mipmapping is disabled by default. + Enables mipmapping if \a enabled is true; otherwise disables it. + + Mipmapping is disabled by default. + If mipmapping is enabled, additional memory will be allocated for the mipmap levels. The mipmap levels can be updated by binding the texture and calling glGenerateMipmap(). Mipmapping cannot be enabled for multisampled framebuffer objects. - \sa mipmap(), texture() + \sa mipmap(), QGLFramebufferObject::texture() */ void QGLFramebufferObjectFormat::setMipmap(bool enabled) { @@ -713,7 +716,7 @@ void QGLFramebufferObjectPrivate::init(QGLFramebufferObject *q, const QSize &sz, as a texture, you first need to copy from it to a regular framebuffer object using QGLContext::blitFramebuffer(). - \section Threading + \section1 Threading As of Qt 4.8, it's possible to draw into a QGLFramebufferObject using a QPainter in a separate thread. Note that OpenGL 2.0 or diff --git a/src/opengl/qglpixelbuffer.cpp b/src/opengl/qglpixelbuffer.cpp index 32785960e1..265d598b1e 100644 --- a/src/opengl/qglpixelbuffer.cpp +++ b/src/opengl/qglpixelbuffer.cpp @@ -77,7 +77,7 @@ \endlist - \section Threading + \section1 Threading As of Qt 4.8, it's possible to render into a QGLPixelBuffer using a QPainter in a separate thread. Note that OpenGL 2.0 or OpenGL ES -- cgit v1.2.3