ItemParticle QML Type

パーティクルをペイントするデリゲートを指定します。詳細...

Import Statement: import QtQuick.Particles
Inherits:

ParticlePainter

プロパティ

方法

物件詳細

プロパティの説明

delegate : Component

デリゲートのインスタンスは、すべての論理パーティクルに対して作成され、パーティクルと一緒に移動します。デリゲートを使用する代わりに、自分でItemインスタンスを作成し、take メソッドを使用して移動させるためにItemParticle

ItemParticle によって作成されたデリゲートインスタンスは、論理パーティクルが期限切れになると破棄されます。


fade : bool

trueの場合、アイテムはライフタイムが終了すると自動的にフェードイン、フェードアウトします。falseの場合は、自分でエントリーエフェクトを実装する必要があります。

デフォルトはtrueです。


メソッドの説明

freeze(Item item)

item が表す論理パーティクルの時間の流れを一時停止し、その動きをコントロールできるようにします。


give(Item item)

ItemParticle に命じて、item の制御をあなたに委ねます。 はその制御を停止し、そのアイテムは論理パーティクルとの関連を失います。


take(Item item, bool prioritize)

ItemParticleitem の位置決めの制御を一時的に引き継ぐように頼む。論理パーティクルが利用可能な場合は、その動きに従います。

デフォルトでは、アイテムは論理パーティクルを待つときにキューを形成しますが、prioritizetrue の場合、すぐにキューの先頭に行きます。

ItemParticle はアイテムの所有権を持たず、論理パーティクルの期限が切れるとコントロールを放棄します。一般的に、この時点でアイテムをキューに戻したいと思うでしょう。そのためには、デリゲート定義の以下の行を使用します:

ItemParticle.onDetached: itemParticleInstance.take(delegateRootItem);

また、デリゲート定義の以下の行のように、削除することもできます:

ItemParticle.onDetached: delegateRootItem.destroy();

unfreeze(Item item)

item が表す論理パーティクルの時間の流れを再開し、パーティクルシステムによって再び動かせるようにします。


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