Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
main.cpp
Go to the documentation of this file.
1
// Copyright (C) 2017 The Qt Company Ltd.
2
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
3
#
include
<
QGuiApplication
>
4
#
include
<
QtQuick
>
5
6
#
include
"myclass.h"
7
8
//![0]
9
int
main
(
int
argc,
char
*argv[]) {
10
QGuiApplication app(argc, argv);
11
12
QQuickView view(QUrl::fromLocalFile(
"MyItem.qml"
));
13
QObject *item = view.rootObject();
14
15
MyClass
myClass;
16
QObject::connect(item, SIGNAL(qmlSignal(QString)),
17
&myClass, SLOT(cppSlot(QString)));
18
19
view.show();
20
return
app.exec();
21
}
22
//![0]
MyClass
[5]
Definition
doc_src_properties.cpp:66
main
int main(int argc, char *argv[])
[ctor_close]
Definition
src_corelib_animation_qpropertyanimation.cpp:100
qtdeclarative
src
qml
doc
snippets
qml
qtbinding
signals-qml
main.cpp
Generated on
for Qt by
1.14.0