このページでは

Qt3DExtras::QExtrudedTextGeometry Class

class Qt3DExtras::QExtrudedTextGeometry

QExtrudedTextGeometry クラスを使用すると、3D 空間に 3D 押し出しテキストを作成することができます。詳細...

ヘッダー: #include <Qt3DExtras/QExtrudedTextGeometry>
CMake: find_package(Qt6 REQUIRED COMPONENTS 3dextras)
target_link_libraries(mytarget PRIVATE Qt6::3dextras)
qmake: QT += 3dextras
QML内: ExtrudedTextGeometry
継承元: Qt3DCore::QGeometry
ステータス: 非推奨

このクラスは非推奨です。新しいコードでの使用は強く推奨しません。

プロパティ

パブリック関数

QExtrudedTextGeometry(Qt3DCore::QNode *parent = nullptr)
float extrusionLength() const
QFont font() const
Qt3DCore::QAttribute *indexAttribute() const
Qt3DCore::QAttribute *normalAttribute() const
Qt3DCore::QAttribute *positionAttribute() const
QString text() const

パブリックスロット

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

シグナル

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

詳細な説明

QExtrudedTextGeometry クラスは、主に QText3DMesh によって内部的に使用されますが、カスタムのQt3DRender::QGeometryRenderer サブクラスでも使用することができます。

ジオメトリの原点は、テキストのベースラインの左後端です。

プロパティのドキュメント

extrusionLength : float

テキストの押し出し長さを保持します。

アクセス関数:

float extrusionLength() const
void setDepth(float extrusionLength)

通知信号:

void depthChanged(float extrusionLength)

font : QFont

テキストのフォントを保持します。

ジオメトリはフォントの pointSize によって正規化されるため、pointSize を大きくすると、テキストのサイズが大きくなるのではなく、滑らかになります。pixelSize は使用しないでください。

アクセス関数:

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

Notifierシグナル:

void fontChanged(const QFont &font)

[read-only] indexAttribute : Qt3DCore::QAttribute* const

ジオメトリ・インデックス属性を保持します。

アクセス関数:

Qt3DCore::QAttribute *indexAttribute() const

[read-only] normalAttribute : Qt3DCore::QAttribute* const

ジオメトリの法線属性を保持します。

アクセス関数:

Qt3DCore::QAttribute *normalAttribute() const

[read-only] positionAttribute : Qt3DCore::QAttribute* const

ジオメトリの位置属性を保持します。

アクセス関数:

Qt3DCore::QAttribute *positionAttribute() const

text : QString

メッシュに使用されるテキストを保持します。

アクセス関数:

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

通知シグナル:

void textChanged(const QString &text)

メンバ関数のドキュメント

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

parent を使用して、新しい QExtrudedTextGeometry を生成します。

© 2026 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.