Details
-
Bug
-
Resolution: Fixed
-
P2: Important
-
None
-
6.2, 6.5, 6.6
-
None
-
macOS 11 or macOS 12
Description
Our application started experiencing crashes in QColorDialog::getColor after switching from Qt 5.15 to Qt 6.2.
The crash shows an assertion failure in macOS code: "Assertion failed: (backingScaleFactor > 0.f), function drawnFocusRingBitmapForTime, file NSAutomaticFocusRing.m, line 346."
Initially I wrote this off as a macOS bug, because partially it is. But further testing showed that it was not present in Qt 5.15.
I'm attaching a very basic sample application that can reproduce the issue, as well as a crash dump file.
Steps to reproduce:
- Be running macOS 11 or 12
- Build the sample application against Qt 6.2 or newer
- Press the 'Color' button to open the color dialog.
- If the saved swatch area has any saved samples, delete those, quit the application, and relaunch it.
- Adjust a color.
- Drag the color swatch (on the bottom left) into one of the saved sample areas.
- The program abruptly terminates.
The issue was introduced with this change:
Reverting that change fixes the issue.