From 47df0eb5131a5fc0decd049bd3f9eefeb26276df Mon Sep 17 00:00:00 2001 From: Volker Hilsheimer Date: Wed, 1 Mar 2023 13:36:32 +0100 Subject: [PATCH] Doc: fix QOpenGLWidget::defaultFramebufferObject documentation Fix the link to QSurfaceFormat::StereoBuffers, and clean the text up a bit. If everything is a \note, then we might just as well not have notes, so move the statement about when this function is useful out of a note, and combine the statements elaborating on ownership and lifetime of framebuffer and contexts into a single note. Pick-to: 6.5 6.5.0 Change-Id: I7cb1f9ff78ba760e99d639550130f5c833ad684a Reviewed-by: Laszlo Agocs --- src/openglwidgets/qopenglwidget.cpp | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/src/openglwidgets/qopenglwidget.cpp b/src/openglwidgets/qopenglwidget.cpp index 68fabc7f14c..6c3a412219a 100644 --- a/src/openglwidgets/qopenglwidget.cpp +++ b/src/openglwidgets/qopenglwidget.cpp @@ -1358,15 +1358,13 @@ GLuint QOpenGLWidget::defaultFramebufferObject() const \return The framebuffer object handle of the specified target buffer or \c 0 if not yet initialized. - \note Calling this overload only makes sense if \l QSurfaceFormat::StereoBuffer is enabled - and supported by the hardware. Will return the default buffer if it's not. + Calling this overload only makes sense if \l QSurfaceFormat::StereoBuffers is enabled + and supported by the hardware. If not, this method will return the default buffer. \note The framebuffer object belongs to the context returned by context() - and may not be accessible from other contexts. - - \note The context and the framebuffer object used by the widget changes when - reparenting the widget via setParent(). In addition, the framebuffer object - changes on each resize. + and may not be accessible from other contexts. The context and the framebuffer + object used by the widget changes when reparenting the widget via setParent(). + In addition, the framebuffer object changes on each resize. \since 6.5