Details
-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
6.2.7, 6.4.2
-
None
-
Ubuntu Desktop 22.04 LTS (x64), macOS Ventura 13.2 (arm64)
Description
Application environment: In a Qt Quick application using ApplicationWindow, having a StackLayout inside which has multiple pages, one at least having a QQuickPaintedItem component.
How to tigger: Maximize window or return back from maximized window.
Expected outcome: In QQuickPaintedItem:: paint() callback width() and height() are correct. Instead width and/or height is bogus and sometimes swapped. Results in incorrectly painted component.
Notes: Normal window resize made from window corner works correctly. Also QQuickPaintedItem:: paint() works correctly when not placed in a StackLayout. So conclusion is that there's a bug in StackLayout resize in above case. Also painter->device()>width() and painter>device()->height() return wrong values in such case.
This may apply to other components contained in a StackLayout as well, but tested only with QQuickPaintedItem derived components. Happens at least on both Linux and macOS. renderTarget() being Image or FrameBuffer doesn't change this behavior.