How to detect QML design mode in Qt Creator
Qt Creator and other tools
2
Posts
1
Posters
1.1k
Views
1
Watching
-
I get this answer somewhere else
Thomas Hartmann says:
December 10, 2014 at 15:36
If you need complex backend data or models, then you can do what is described here: http://blog.qt.digia.com/blog/2011/07/28/mockup-data-for-the-qml-designer/But with Qt Creator 3.3 we introduced a new ui.qml file format. In this case your code is split into full QML and a subset (in the .ui.qml file) for the designer. Then you can define any values and even models in the .ui.qml file and overwrite those in the qml file that contains the implementation.
See: http://doc-snapshot.qt-project.org/qtcreator-3.3/creator-quick-ui-forms.html