From dc124f20691f4df4567de3db56ad15bb999370c3 Mon Sep 17 00:00:00 2001 From: Christian Ehrlicher Date: Fri, 4 Oct 2024 21:45:07 +0200 Subject: [PATCH] QCommonStyle: pass orientation to PE_IndicatorProgressChunk When drawing the chunks for the progress bar, we now have to pass at least the State_Horizontal bit because the orientation member of QStyleOptionProgressBar was replaced with this state bit. Pick-to: 6.7 6.5 Fixes: QTBUG-129386 Change-Id: Ibc8b6b315609cdd1a6f949ae2116728b7c6bded8 Reviewed-by: Axel Spoerl (cherry picked from commit d399bdddc6e71617e045fc77e70abef3ed2ee006) Reviewed-by: Qt Cherry-pick Bot --- src/widgets/styles/qcommonstyle.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/widgets/styles/qcommonstyle.cpp b/src/widgets/styles/qcommonstyle.cpp index af163669a08..de913350468 100644 --- a/src/widgets/styles/qcommonstyle.cpp +++ b/src/widgets/styles/qcommonstyle.cpp @@ -1638,7 +1638,7 @@ void QCommonStyle::drawControl(ControlElement element, const QStyleOption *opt, pbBits.palette = pal2; int myY = pbBits.rect.y(); int myHeight = pbBits.rect.height(); - pbBits.state = State_None; + pbBits.state &= QStyle::State_Horizontal; // all other is irrelevant here for (int i = 0; i < nu; ++i) { pbBits.rect.setRect(x0 + x, myY, unit_width, myHeight); pbBits.rect = m.mapRect(QRectF(pbBits.rect)).toRect();