2
創建我有加載另一個QML通行證屬性對象由QML裝載機
Loader { id: gaugeLoader }
PieMenu {
id: pieMenu
MenuItem {
text: "Add Bar Gauge"
onTriggered: gaugeLoader.source = "qrc:/Gauges/horizontalBarGauge.qml"
}
MenuItem {
text: "Action 2"
onTriggered: print("Action 2")
}
MenuItem {
text: "Action 3"
onTriggered: print("Action 3")
}
}
我如何可以傳遞參數來設置加載QML的ID
,width
,height
等一個QML Loader
?