ItemModelScatterDataProxy QML Type

Proxy class for presenting data in item models with Scatter3D . 更多...

import 語句: import QtGraphs
在 C++: QItemModelScatterDataProxy
繼承:

ScatterDataProxy

特性

信號

詳細描述

This type allows you to use AbstractItemModel derived models as a data source for Scatter3D .

The data is resolved asynchronously whenever the mapping or the model changes. QScatterDataProxy::arrayReset () is emitted when the data has been resolved.

更多細節,見 QItemModelScatterDataProxy 文檔編製。

用法範例:

ItemModelScatterDataProxy {
    itemModel: model // E.g. a list model defined elsewhere containing point coordinates.
    // Mapping model roles to scatter series item coordinates.
    xPosRole: "xPos"
    yPosRole: "yPos"
    zPosRole: "zPos"
}
					

另請參閱 ScatterDataProxy and Qt Graphs Data Handling with 3D .

特性文檔編製

itemModel : model

The item model to use as a data source for Scatter3D .

rotationRole : string

The item model role to map into item rotation. The model may supply the value for rotation as either variant that is directly convertible to quaternion , or as one of the string representations: "scalar,x,y,z" or "@angle,x,y,z" . The first format will construct the quaternion directly with given values, and the second one will construct the quaternion 使用 QQuaternion::fromAxisAndAngle () 方法。

rotationRolePattern : regExp

When set, a search and replace is done on the value mapped by the rotation role before it is used as item rotation. This property specifies the regular expression to find the portion of the mapped value to replace, and rotationRoleReplace property contains the replacement string.

另請參閱 rotationRole and rotationRoleReplace .

rotationRoleReplace : string

This property defines the replacement content to be used in conjunction with rotationRolePattern . Defaults to an empty string. For more information on how the search and replace using regular expressions works, see the QString::replace (const QRegularExpression &rx, const QString &after) function documentation.

另請參閱 rotationRole and rotationRolePattern .

type : AbstractDataProxy . DataType [read-only]

The type of the proxy. One of the QAbstractDataProxy::DataType 值。

xPosRole : string

The item model role to map into the X position.

xPosRolePattern : regExp

When set, a search and replace is done on the value mapped by the x-position role before it is used as an item position value. This property specifies the regular expression to find the portion of the mapped value to replace, and xPosRoleReplace property contains the replacement string.

另請參閱 xPosRole and xPosRoleReplace .

xPosRoleReplace : string

This property defines the replacement content to be used in conjunction with xPosRolePattern . Defaults to an empty string. For more information on how the search and replace using regular expressions works, see the QString::replace (const QRegularExpression &rx, const QString &after) function documentation.

另請參閱 xPosRole and xPosRolePattern .

yPosRole : string

The item model role to map into the Y position.

yPosRolePattern : regExp

When set, a search and replace is done on the value mapped by the y-position role before it is used as an item position value. This property specifies the regular expression to find the portion of the mapped value to replace, and yPosRoleReplace property contains the replacement string.

另請參閱 yPosRole and yPosRoleReplace .

yPosRoleReplace : string

This property defines the replacement content to be used in conjunction with yPosRolePattern . Defaults to an empty string. For more information on how the search and replace using regular expressions works, see the QString::replace (const QRegularExpression &rx, const QString &after) function documentation.

另請參閱 yPosRole and yPosRolePattern .

zPosRole : string

The item model role to map into the Z position.

zPosRolePattern : regExp

When set, a search and replace is done on the value mapped by the z-position role before it is used as an item position value. This property specifies the regular expression to find the portion of the mapped value to replace, and zPosRoleReplace property contains the replacement string.

另請參閱 zPosRole and zPosRoleReplace .

zPosRoleReplace : string

This property defines the replacement content to be used in conjunction with zPosRolePattern . Defaults to an empty string. For more information on how the search and replace using regular expressions works, see the QString::replace (const QRegularExpression &rx, const QString &after) function documentation.

另請參閱 zPosRole and zPosRolePattern .

信號文檔編製

itemModelChanged ( model itemModel )

此信號發射,當 itemModel changes to itemModel .

注意: 相應處理程序是 onItemModelChanged .

rotationRoleChanged ( string role )

此信號發射,當 rotationRole changes to role .

注意: 相應處理程序是 onRotationRoleChanged .

rotationRolePatternChanged ( regExp pattern )

此信號發射,當 rotationRolePattern changes to pattern .

注意: 相應處理程序是 onRotationRolePatternChanged .

rotationRoleReplaceChanged ( string replace )

此信號發射,當 rotationRoleReplace changes to replace .

注意: 相應處理程序是 onRotationRoleReplaceChanged .

xPosRoleChanged ( string role )

此信號發射,當 xPosRole changes to role .

注意: 相應處理程序是 onXPosRoleChanged .

xPosRolePatternChanged ( regExp pattern )

此信號發射,當 xPosRolePattern changes to pattern .

注意: 相應處理程序是 onXPosRolePatternChanged .

xPosRoleReplaceChanged ( string replace )

此信號發射,當 xPosRoleReplace changes to replace .

注意: 相應處理程序是 onXPosRoleReplaceChanged .

yPosRoleChanged ( string role )

此信號發射,當 yPosRole changes to role .

注意: 相應處理程序是 onYPosRoleChanged .

yPosRolePatternChanged ( regExp pattern )

此信號發射,當 yPosRolePattern changes to pattern .

注意: 相應處理程序是 onYPosRolePatternChanged .

yPosRoleReplaceChanged ( string replace )

此信號發射,當 yPosRoleReplace changes to replace .

注意: 相應處理程序是 onYPosRoleReplaceChanged .

zPosRoleChanged ( string role )

此信號發射,當 zPosRole changes to role .

注意: 相應處理程序是 onZPosRoleChanged .

zPosRolePatternChanged ( regExp pattern )

此信號發射,當 zPosRolePattern changes to pattern .

注意: 相應處理程序是 onZPosRolePatternChanged .

zPosRoleReplaceChanged ( string replace )

此信號發射,當 zPosRoleReplace changes to replace .

注意: 相應處理程序是 onZPosRoleReplaceChanged .