Qt3DExtras::QExtrudedTextMesh Class

class Qt3DExtras::QExtrudedTextMesh

三维挤出文本网格更多

头文件: #include <Qt3DExtras/QExtrudedTextMesh>
CMake: find_package(Qt6 REQUIRED COMPONENTS 3dextras)
target_link_libraries(mytarget PRIVATE Qt6::3dextras)
qmake: QT += 3dextras
在 QML 中: ExtrudedTextMesh
继承: Qt3DRender::QGeometryRenderer
状态:已废弃

属性

公共功能

QExtrudedTextMesh(Qt3DCore::QNode *parent = nullptr)
float depth() const
QFont font() const
QString text() const

公共插槽

void setDepth(float depth)
void setFont(const QFont &font)
void setText(const QString &text)

信号

void depthChanged(float depth)
void fontChanged(const QFont &font)
void textChanged(const QString &text)

详细说明

网格的原点是文字基线的左后方。

属性文档

depth : float

保存文字的挤出深度。

访问功能:

float depth() const
void setDepth(float depth)

通知信号:

void depthChanged(float depth)

font : QFont

表示文字的字体。

网格几何图形按字体的 pointSize 进行归一化处理,因此,pointSize 越大,文字越平滑,而不是越大。

访问功能:

QFont font() const
void setFont(const QFont &font)

通知信号

void fontChanged(const QFont &font)

text : QString

保存用于网格的文本。

访问功能:

QString text() const
void setText(const QString &text)

Notifier 信号:

void textChanged(const QString &text)

成员函数 文档

[explicit] QExtrudedTextMesh::QExtrudedTextMesh(Qt3DCore::QNode *parent = nullptr)

使用parent 构建一个新的 QText3DMesh。

© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.