1 | // Copyright (C) 2016 Klaralvdalens Datakonsult AB (KDAB). |
2 | // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only |
3 | |
4 | #ifndef QT3DEXTRAS_QTEXT2DENTITY_H |
5 | #define |
6 | |
7 | #include <QtCore/qrect.h> |
8 | #include <QtGui/qcolor.h> |
9 | #include <QtGui/qfont.h> |
10 | #include <Qt3DCore/qentity.h> |
11 | #include <Qt3DExtras/qt3dextras_global.h> |
12 | |
13 | QT_BEGIN_NAMESPACE |
14 | |
15 | namespace Qt3DExtras { |
16 | |
17 | class ; |
18 | |
19 | class Q_3DEXTRASSHARED_EXPORT : public Qt3DCore::QEntity |
20 | { |
21 | Q_OBJECT |
22 | Q_PROPERTY(QFont font READ font WRITE setFont NOTIFY fontChanged) |
23 | Q_PROPERTY(QString text READ text WRITE setText NOTIFY textChanged) |
24 | Q_PROPERTY(QColor color READ color WRITE setColor NOTIFY colorChanged) |
25 | Q_PROPERTY(float width READ width WRITE setWidth NOTIFY widthChanged) |
26 | Q_PROPERTY(float height READ height WRITE setHeight NOTIFY heightChanged) |
27 | |
28 | public: |
29 | explicit (Qt3DCore::QNode *parent = nullptr); |
30 | (); |
31 | |
32 | QFont () const; |
33 | void (const QFont &font); |
34 | |
35 | QColor () const; |
36 | void (const QColor &color); |
37 | |
38 | QString () const; |
39 | void (const QString &text); |
40 | |
41 | float () const; |
42 | float () const; |
43 | |
44 | void (float width); |
45 | void (float height); |
46 | |
47 | Q_SIGNALS: |
48 | void (const QFont &font); |
49 | void (const QColor &color); |
50 | void (const QString &text); |
51 | void (float width); |
52 | void (float height); |
53 | |
54 | private: |
55 | Q_DECLARE_PRIVATE(QText2DEntity) |
56 | }; |
57 | |
58 | } // namespace Qt3DExtras |
59 | |
60 | QT_END_NAMESPACE |
61 | |
62 | #endif // QT3DEXTRAS_QTEXT2DENTITY_H |
63 | |