Enable strict mode 6.11+ in qtcanvaspainter


Impressive that all that was found was a missing context object
(QT_NO_CONTEXTLESS_CONNECT).

To fix it, use the source object, which is what the 3-arg connect() is
doing implicitly. The lambda doesn't reference any other QObject that
we could use here (this is not a QObject, and neither is m_factory).

We cannot set QT_LEAN_HEADERS to its latest value, 2, because QML
headers are only level-1 clean.

Pick-to: 6.11
Fixes: QTBUG-145277
Change-Id: Ifa7e85889d5bfa3961fe60cf5b5763095528cd05
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
commitb039c97b9cfffbd4c001e31f86ce8d59242eafd9
parent38bf2d0dbdd3124399cd4b2e4b1e94a5674c368c
authorMarc Mutz <marc.mutz@qt.io>
committerMarc Mutz <marc.mutz@qt.io>
commit timeFri, 27 Mar 2026 16:06:14 +0100