From a4dc60e9fcf5e5131d620240bb0abdca9911e82c Mon Sep 17 00:00:00 2001 From: Shawn Rutledge Date: Tue, 21 Jan 2025 19:08:00 +0100 Subject: [PATCH] doc: Improve QTextTableFormat::setBorderCollapse and related docs We changed the default in 6.8. It was documented in the changelog but not in docs. Amends 09ea47f8113bdce437253b19a91f739aeef7a333 Pick-to: 6.8 Fixes: QTBUG-132173 Change-Id: I1b6bf69931ba12025cf95e80c12a5073a94af598 Reviewed-by: Paul Wicking (cherry picked from commit 622133ace2533617f294b8d875b5eb749a78571b) Reviewed-by: Qt Cherry-pick Bot --- src/gui/text/qtextformat.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/gui/text/qtextformat.cpp b/src/gui/text/qtextformat.cpp index 161cfb1abad..73b0e769169 100644 --- a/src/gui/text/qtextformat.cpp +++ b/src/gui/text/qtextformat.cpp @@ -3291,7 +3291,7 @@ QTextTableFormat::QTextTableFormat(const QTextFormat &fmt) \fn void QTextTableFormat::setBorderCollapse(bool borderCollapse) \since 5.14 - Enabling \a borderCollapse will have the following implications: + By default, \l borderCollapse() is \c true, which has the following implications: \list \li The borders and grid of the table will be rendered following the CSS table \c border-collapse: \c collapse rules @@ -3308,10 +3308,12 @@ QTextTableFormat::QTextTableFormat(const QTextFormat &fmt) \endlist \endlist - With borderCollapse disabled, cell borders can still be styled + With \a borderCollapse set to \c false, cell borders can still be styled using QTextTableCellFormat but styling will be applied only within the cell's frame, which is probably not very useful in practice. + \note In Qt versions prior to 6.8, the default value was \c false. + \sa setBorder(), setBorderBrush(), setBorderStyle() \sa QTextTableCellFormat */ @@ -3320,7 +3322,7 @@ QTextTableFormat::QTextTableFormat(const QTextFormat &fmt) \fn bool QTextTableFormat::borderCollapse() const \since 5.14 - Returns true if borderCollapse is enabled. + Returns \c true if table borders are to be collapsed. The default is \c true. \sa setBorderCollapse() */