123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
- #include <QGuiApplication>
- #include <QQmlApplicationEngine>
- #include <QQmlContext>
- #include <QDebug>
- #include <QtProtobufTypes>
- #include "handwritingengine.h"
- int main(int argc, char *argv[])
- {
- QtProtobuf::qRegisterProtobufTypes();
- QGuiApplication app(argc, argv);
- HandwritingEngine hwengine;
- QQmlApplicationEngine engine;
- engine.rootContext()->setContextProperty("hwengine", &hwengine);
- engine.load(QUrl(QStringLiteral("qrc:/main.qml")));
- if (engine.rootObjects().isEmpty())
- return -1;
- return app.exec();
- }
|