[Interest] Qt on macOS 10.14 Mojave

Morten Sørvig Morten.Sorvig at qt.io
Wed Jul 4 16:19:14 CEST 2018

Hi all,

macOS 10.14 is now in (public) beta and we've had some time to test Qt on it.

This time there are (at least) two changes which will impact Qt applications:
Core Animation layer backed NSViews/QWindows and dark mode. We’re aiming to
have improvements in place for Qt 5.12. See below for specific details.

In the mean time it’s possible to continue developing and shipping applications
for macOS 10.14, also using current Qt versions. This can be done by linking
against the 10.13 (or earlier) SDK, which will opt out of dark mode support 
and layer backing. It is the syslibroot argument on the linker line which
determines the SDK version for this purpose, for example:


Dark appearance: In theory, applications should pick up the dark appearance via
the style and palette. In practice, they may not due to incomplete/buggy QPalette
and QMacStyle implementations, or hardcoded colors in Qt or the application.

The current state of the patches for dev/5.12 is that custom-styled applications
can work well in dark mode, for example Qt Creator with a dark theme.

The plan is to disable dark mode support by default in Qt, at least until
QMacStyle is fixed. This means that applications will start up using standard
Aqua theme/colors, also when the desktop is configured for dark mode.

The application has the final call here, and can opt in or out by setting the
NSRequiresAquaSystemAppearance key in the Info.plist file. For example:


will indicate that the app _does_ support dark mode, and Qt will get out
of the way and not apply its disable. Setting it to true will insulate the
app against any changes in the Qt default.

Layer backing: We are seeing some issues here, in particular related to
multithreaded OpenGL (as used by the default threaded Qt Quick render loop).
We are sorting out if this is something that can or should be fixed in Qt.

So far we’ve not found a way to opt out of layer backing when on the 10.14
SDK, so linking against an earlier SDK looks to be the only opt-out option

If you want to file a bug for something that is not working, then please
make sure it has “Mojave” somewhere in the title and we’ll sort it into
the correct in pile.

Thanks for reading!

More information about the Interest mailing list