When two widgets are created and one moves under the second widget, the second widget's drawing will be incorrect.
The attaches sample project draws objects as below.
How to reproduce
1. Build Qt with the following configuration
2. Use qtbug98911-mdi-incorrectDrawing.zip (modified version of Qt mdi example) and run with #1
3. Click on the New tool button to create two widgets.
4. Click on the Cut tool button to move the first widget.
5. As it moves under the second widget, the second widget's drawing will be incorrect.
6. Resize the window to force both widgets to repaint correctly.
7. Click Copy to move the first widget so that its top left is offscreen, and it will now be drawn incorrectly. Resizing the window does not produce the correct result in this case.
Static Qt build environment : Qt6.2.1, M1, Xcode 13.1, macOS 11.6.
Project build environment : Qt6.2.1, M1, Xcode 13.1, macOS 11.6.
What is known
- This does NOT happen with pre-build Qt 6.2.1
- This does NOT happen on M1(ARM) with the static libs.