[Interest] what are the requirements for QMetaType::metaObjectForType(QMetaType::type("QQuickLayout*")) to work?
Ulf Hermann
ulf.hermann at qt.io
Mon May 6 13:24:50 CEST 2024
> That means it's relying on some automatic registration somewhere, somehow.
QQuickLayout has a QML_NAMED_ELEMENT macro which means it's picked up by
qmltyperegistrar which does what it says. Of course it only does that if
you actually import QtQuick somewhere. That's probably the difference
between the two cases.
> That's poor programming practice.
No.
best regards,
Ulf
More information about the Interest
mailing list