[Development] QtCon 2016 session notes: Qt for macOS

Morten Sorvig Morten.Sorvig at qt.io
Mon Sep 12 11:37:58 CEST 2016

Session held friday september 2nd. 

Around 15 persons in attendance, with a good mix of full-time Qt developers,
Qt contributors, and Qt application developers.

1) We briefly went through the work on QTBUG-49827 (Qt on macOS Graphics/integration update):

   Development of native autotests and manual tests.
   Layer-backed QWindows.
   Color space support.
   Improving support for embedding QWindow in native view hierarchies.

This was mostly information sharing. Some questions were asked (and answered):

Q: Should layer mode be enabled by default, like on UIKit? 
A: Maybe. Let’s make it work first.

Q: Will this require changes to application code? 
A: The goal is no changes to application code. Some changes to non-platform plugin code may
   be wanted, for example all QWindow users should drive animations using QWindow::requestUpdate().

2) We discussed dropping 32-bit support, which will enable us to (easily) use automated reference
counting (ARC) internally. As of today Qt does not support any 32-bit mac hardware, the only 
reason for keeping 32-bit going is to support applications with 32-bit components (non 64-bit 
clean source code or 32-bit only binaries). Other Apple platforms are 64-bit only.

In favor of keeping 32-bit support is the normal “Qt runs everywhere” argument, and not
having macOS be the only (desktop) port without 32-bit support.

Recommendation: We deprecate/obsolete 32-bit builds and phase in ARC usage in all apple-platform code.

3) Notifications: 

   There are patches for improving native notification support.
	https://codereview.qt-project.org/#/c/166456/ (and one more)
   Do we want a new module? Cross-platform support via plugins.
   Can the deprecate existing QSystrayIcon/platform plugin support
   Some API revising needed. Do we want a signal-slot API to support
   user interaction with the notification.

4) Optional private API usage.

We may be able to improve e.g. the Mac style (see below) by using private API.
Apparently there are instances of private API usage on the App store, also from
“big name” applications.

Recommendation: Okay as long as applications have to opt-in to taking the risk
(the default Qt build is app-store compliant)

5) Styling:
  The mac style can be improved, with some/much effort.
  At the same time it does not help us in the native “feel”.
  Improvement: use new (10.7) alignment rectangle API.
  Improvement: perhaps also by using the CoreUI private framework directly.
  If exact native behavior is needed: use native components, for example NSToolBar
  directly, or wrapped via QMacToolBar.
  Meta-point: how do we (Qt) deal with continuing platform divergence?

We ran out of time and may have missed some topics and/or input - following up on
this email is possible.


More information about the Development mailing list