[Interest] Tracking down a macOS drawing bug
aclight at gmail.com
Wed Jun 17 01:07:50 CEST 2020
We recently discovered a bug in our application that uses Qt 5.12.8 and
we're having a hard time figuring out what might be going wrong. This is in
a subclass of QPlainTextEdit.
The bug presents in the following way:
If you have a line of text selected, such as "abcd;abcd;abcd;abcd;", and
use our replace bar to replace "abcd" with "foo", and then replace all
instances in the selected text, the widget still
displays "abcd;abcd;abcd;abcd;" with the original selection until something
forces the entire window to redraw (eg. the application is deactivated or
the window is resized).
This might sound like a bug in our application but we only see the bug when
both of the following are true:
1. The application is built on a machine with macOS 10.15.5 and Xcode 11.5
2. The application is running on macOS 10.14 or 10.15 but NOT 10.13
We are using the exact same copy of the Qt framework in all cases, built on
macOS 10.14 with Xcode 10.2.
The fact that we don't see this running macOS 10.13 suggests that it has
something to do with layer-backed views.
The fact that we can reproduce the bug when running the application on
10.15 and 10.14 suggests that it's not (just?) an OS bug.
We cannot reproduce the problem if we build our application with Xcode
11.2, but we can using Xcode 11.5. We haven't tried anything in between.
Is there Qt drawing code that behaves differently when the **application**
is **built** with the 10.15 SDK versus the 10.14 SDK? The only relevant
test I can see for this is in qnsview_drawing.mm (layerEnabledByMacOS())
but that test treats Mojave and Catalina the same.
Does this sound familiar to anyone?
Thanks for any ideas
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Interest