12 #include <QQuickWidget> 19 QQuickWidget* pv =
new QQuickWidget(QUrl(
"qrc:/main.qml"));
20 QVBoxLayout* pvbx =
new QVBoxLayout;
24 QQuickItem* pqiRoot = pv->rootObject();
26 pqiRoot->setProperty(
"color",
"yellow");
28 QObject* pObjText = pqiRoot->findChild<QObject*>(
"text");
30 pObjText->setProperty(
"text",
"C++");
31 pObjText->setProperty(
"color",
"blue");
34 QMetaObject::invokeMethod(pObjText,
36 Q_RETURN_ARG(QVariant, varRet),