Код: Выделить всё
00:51:26: Starting /home/pietro/QtQuickTest/build/Desktop_latest-Debug/appQtQuickTest...
QML debugging is enabled. Only use this in a safe environment.
QQmlApplicationEngine failed to load component
qrc:/qt/qml/main.qml: No such file or directory
Исходный файл main.qml находится в корневом каталоге проекта ., а копия создается во время сборки в ./build/Desktop_latest-Debug/appQtQuickTest/.
В main.cpp есть строка:
Код: Выделить всё
engine.load(QUrl(QStringLiteral("qrc:/qt/qml/main.qml")));
Код: Выделить всё
engine.load(QUrl(QStringLiteral("qrc:/main.qml")));
Что я делаю не так?
Подробнее здесь: https://stackoverflow.com/questions/793 ... n-qml-file