1 | // Copyright (C) 2017 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_QEXTRUDEDTEXTMESH_H |
5 | #define QT3DEXTRAS_QEXTRUDEDTEXTMESH_H |
6 | |
7 | #include <Qt3DExtras/qt3dextras_global.h> |
8 | #include <Qt3DRender/qgeometryrenderer.h> |
9 | #include <QtCore/QString> |
10 | #include <QtGui/QFont> |
11 | |
12 | QT_BEGIN_NAMESPACE |
13 | |
14 | namespace Qt3DExtras { |
15 | |
16 | class Q_3DEXTRASSHARED_EXPORT QExtrudedTextMesh : public Qt3DRender::QGeometryRenderer |
17 | { |
18 | Q_OBJECT |
19 | Q_PROPERTY(QString text READ text WRITE setText NOTIFY textChanged) |
20 | Q_PROPERTY(QFont font READ font WRITE setFont NOTIFY fontChanged) |
21 | Q_PROPERTY(float depth READ depth WRITE setDepth NOTIFY depthChanged) |
22 | |
23 | public: |
24 | explicit QExtrudedTextMesh(Qt3DCore::QNode *parent = nullptr); |
25 | ~QExtrudedTextMesh(); |
26 | |
27 | QString text() const; |
28 | QFont font() const; |
29 | float depth() const; |
30 | |
31 | public Q_SLOTS: |
32 | void setText(const QString &text); |
33 | void setFont(const QFont &font); |
34 | void setDepth(float depth); |
35 | |
36 | Q_SIGNALS: |
37 | void textChanged(const QString &text); |
38 | void fontChanged(const QFont &font); |
39 | void depthChanged(float depth); |
40 | }; |
41 | |
42 | } // namespace Qt3DExtras |
43 | |
44 | QT_END_NAMESPACE |
45 | |
46 | #endif // QT3DEXTRAS_QEXTRUDEDTEXTMESH_H |
47 |