Aroli Marcellinus
Aroli Marcellinus

Reputation: 115

Converting Qt Design Studio UI Projects into Qt Creator qmake Projects

I want to customize the UI from the WebinarDemo in Qt Design Studio. Before that, I want to try whether I can deploy it into Qt Creator or not.

I tried the guide from official Qt website about converting Design Studio projects into Qt Creator projects: https://doc.qt.io/qtdesignstudio/quick-converting-ui-projects.html

I succeed to build the ProgressBar project using this guide. So, I tried to follow the same thing using WebinarDemo example. What I did was just making qml folder, in the empty QtQuick project, copy the whole WebinarDemo project content into qml folder, and set up the .pro files like the tutorial mentioned. As for the qml that I called from main.cpp, I called main.qml from WebinarDemo

#include <QGuiApplication>
#include <QQmlApplicationEngine>
#include <QQuickView>

int main(int argc, char *argv[])
{
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
    QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
#endif
    QGuiApplication app(argc, argv);

    QQuickView view;
    view.engine()->addImportPath("qrc:/qml/imports");
    view.setSource(QUrl("qrc:/qml/main.qml"));
    if (!view.errors().isEmpty())
        return -1;
    view.show();

    return app.exec();
}

However, when I did that, an error message appeared that said:

qrc:/qml/main.qml:31:1: module "content" is not installed 
     import content 
     ^

main.qml:
import QtQuick
import content

App {
}

I didn't modify anything from the WebinarDemo. I just want to deploy as it was. However, something like library not found error was occured. How should I solve this? Is there anyone who tried to deploy this example into Qt Creator? If so, I would like to ask more.

Upvotes: 1

Views: 911

Answers (0)

Related Questions