【发布时间】:2013-08-02 14:46:07
【问题描述】:
我的应用程序提供了在运行时编辑某些 QML 对象属性的可能性。 是否可以像 Qt 设计器那样显示 QML 属性以进行编辑?
例如,我有 QML 文件
import QtQuick 2.0
Rectangle {
id: circle
color: "red"
border.color: "black"
border.width: 1
/* allow to modificate by user */
opacity: 0.5
width: 16
height: 16
radius: width*0.5
}
创建后,我想允许用户在运行时更改它的一些属性。 是否可以使用 Qt 设计器类/插件/任何东西来显示其属性并允许对其进行编辑?
我不想重新发明轮子。 :)
【问题讨论】:
-
我发现,在Qt creator中是如何完成的:qt.gitorious.org/qt-creator/qt-creator/blobs/…需要了解是否可以重用