From 5a03dfa249a270fed2c73b6d6a64a79e80eda583 Mon Sep 17 00:00:00 2001 From: Christian Ehrlicher Date: Sat, 23 Mar 2019 21:22:18 +0100 Subject: [PATCH] QTextOption: fix handling Qt::AlignBaseline QTextOption stores the Qt::Alignment flag in a eight bit bitfield. When Qt::AlignBaseline was added the bitfield was not extended so the newly used ninth bit is not stored in QTextOption. Fix it by using one of the unused bits. Simply extending the bitfield is not binary compatible so this has to wait for Qt6. Fixes: QTBUG-74652 Change-Id: I2539f5619ffe729459102fa5406fb6c0dd463ea1 Reviewed-by: Shawn Rutledge --- src/gui/text/qtextoption.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gui/text/qtextoption.h b/src/gui/text/qtextoption.h index a90d73dc43..808076603a 100644 --- a/src/gui/text/qtextoption.h +++ b/src/gui/text/qtextoption.h @@ -133,11 +133,11 @@ public: bool useDesignMetrics() const { return design; } private: - uint align : 8; + uint align : 9; uint wordWrap : 4; uint design : 1; uint direction : 2; - uint unused : 17; + uint unused : 16; uint unused2; // ### Qt 6: remove unnecessary, extra 32 bits uint f; qreal tab;