PySide6.QtGraphs.QAbstract3DSeries

class QAbstract3DSeries

QAbstract3DSeries 类是所有3D数据系列的基础类。更多

PySide6.QtGraphs.QAbstract3DSeries 的继承图

继承自: QSurface3DSeries, QScatter3DSeries, QBar3DSeries

概要

属性

方法

信号

注意

本文档可能包含从C++自动翻译到Python的代码片段。我们始终欢迎对代码片段翻译的贡献。如果您发现翻译问题,您也可以通过在我们的https:/bugreports.qt.io/projects/PYSIDE上创建工单来告知我们。

详细描述

每个支持的系列类型都有继承的类:QBar3DSeriesQScatter3DSeriesQSurface3DSeries

有关更多信息,请参见 Qt Graphs Data Handling with 3D

class SeriesType

系列的类型。

常量

描述

QAbstract3DSeries.SeriesType.None

没有系列类型。

QAbstract3DSeries.SeriesType.Bar

Q3DBarsWidgetItem 的系列类型。

QAbstract3DSeries.SeriesType.Scatter

Q3DScatterWidgetItem 的系列类型。

QAbstract3DSeries.SeriesType.Surface

Q3DSurfaceWidgetItem 的系列类型。

class Mesh

预定义的网格类型。并非所有样式都适用于所有图表类型。

常量

描述

QAbstract3DSeries.Mesh.UserDefined

用户定义的网格,通过userDefinedMesh属性设置。

QAbstract3DSeries.Mesh.Bar

基本的矩形条。

QAbstract3DSeries.Mesh.Cube

基本立方体。

QAbstract3DSeries.Mesh.Pyramid

四棱锥。

QAbstract3DSeries.Mesh.Cone

基本圆锥体。

QAbstract3DSeries.Mesh.Cylinder

基本圆柱体。

QAbstract3DSeries.Mesh.BevelBar

轻微斜角(圆角)矩形条。

QAbstract3DSeries.Mesh.BevelCube

略微倒角(圆角)的立方体。

QAbstract3DSeries.Mesh.Sphere

球体。

QAbstract3DSeries.Mesh.Minimal

最小的3D网格:一个三角锥。仅适用于Q3DScatterWidgetItem

QAbstract3DSeries.Mesh.Arrow

箭头指向上方。

QAbstract3DSeries.Mesh.Point

2D点。仅适用于Q3DScatterWidgetItem。阴影不影响此样式。此样式不支持颜色样式ObjectGradient

注意

当使用from __feature__ import true_property时,属性可以直接使用,否则通过访问器函数使用。

property baseColorᅟ: QColor

此属性保存系列的基础颜色。

另请参阅

colorStyle seriesColors

Access functions:
property baseGradientᅟ: QLinearGradient

此属性保存系列的基础渐变。

Access functions:
property colorStyleᅟ: QGraphsTheme.ColorStyle

此属性保存系列的颜色样式。

另请参阅

ColorStyle

Access functions:
property itemLabelᅟ: str

此属性保存格式化后的项目标签。

如果没有选中的项目或选中的项目不可见,则返回一个空字符串。

另请参阅

itemLabelFormat

Access functions:
property itemLabelFormatᅟ: str

此属性保存此系列中数据项的标签格式。

此格式用于单个项目标签,例如,当选择一个项目时。格式的解释方式取决于系列类型。

Access functions:
property itemLabelVisibleᅟ: bool

此属性控制图表中项目标签的可见性。

如果 true,项目标签会在图表中绘制为浮动标签。否则,项目标签不会绘制。要在外部控件中显示项目标签,此属性设置为 false。默认为 true

另请参阅

itemLabelFormat itemLabel

Access functions:
property meshᅟ: QAbstract3DSeries.Mesh

此属性保存系列中项目的网格。

对于QSurface3DSeries,此属性保存选择指针。

如果网格是MeshUserDefined,那么为了正确渲染项目,还必须设置userDefinedMesh属性。默认值取决于图表类型。

Access functions:
property meshRotationᅟ: QQuaternion

此属性保存应用于系列所有项目的网格旋转。

旋转应该是一个归一化的QQuaternion。对于那些支持特定项目旋转的系列类型,旋转会相乘在一起。QBar3DSeries忽略任何不围绕y轴的旋转。QSurface3DSeries仅将旋转应用于选择指针。默认为无旋转。

Access functions:
property meshSmoothᅟ: bool

此属性用于确定是否使用预定义网格的平滑版本。

如果 true,则使用通过 mesh 属性设置的平滑版本。此属性不影响在网格设置为 MeshUserDefined 时使用的自定义网格。默认为 false

Access functions:
property multiHighlightColorᅟ: QColor

此属性保存系列的多项高亮颜色。

Access functions:
property multiHighlightGradientᅟ: QLinearGradient

此属性保存系列的多项高亮渐变。

Access functions:
property nameᅟ: str

此属性保存系列名称。

系列名称可以在项目标签格式中使用标签 @seriesName

另请参阅

itemLabelFormat

Access functions:
property singleHighlightColorᅟ: QColor

此属性保存系列的单项目高亮颜色。

Access functions:
property singleHighlightGradientᅟ: QLinearGradient

此属性保存系列的单项目高亮渐变。

Access functions:
property typeᅟ: QAbstract3DSeries.SeriesType

此属性保存系列的类型。

Access functions:
property userDefinedMeshᅟ: str

此属性保存用户为对象定义的自定义网格的文件名。

mesh为MeshUserDefined时,使用自定义网格。

注意

文件需要是QtQuick3D网格格式。使用balsam转换工具从其他3D模型格式创建网格。

Access functions:
property visibleᅟ: bool

此属性保存系列的可见性。

如果此属性为false,则不会渲染该系列。默认为true

Access functions:
baseColor()
Return type:

QColor

另请参阅

setBaseColor()

属性 baseColorᅟ 的获取器。

baseColorChanged(color)
Parameters:

颜色QColor

属性 baseColorᅟ 的通知信号。

baseGradient()
Return type:

QLinearGradient

另请参阅

setBaseGradient()

属性 baseGradientᅟ 的获取器。

baseGradientChanged(gradient)
Parameters:

渐变QLinearGradient

属性 baseGradientᅟ 的通知信号。

colorStyle()
Return type:

ColorStyle

另请参阅

setColorStyle()

属性 colorStyleᅟ 的获取器。

colorStyleChanged(style)
Parameters:

styleColorStyle

属性 colorStyleᅟ 的通知信号。

isItemLabelVisible()
Return type:

布尔

属性 itemLabelVisibleᅟ 的获取器。

isMeshSmooth()
Return type:

布尔

属性 meshSmoothᅟ 的获取器。

isVisible()
Return type:

布尔

属性 visibleᅟ 的获取器。

itemLabel()
Return type:

字符串

属性 itemLabelᅟ 的获取器。

itemLabelChanged(label)
Parameters:

标签 – str

属性 itemLabelᅟ 的通知信号。

itemLabelFormat()
Return type:

字符串

另请参阅

setItemLabelFormat()

属性 itemLabelFormatᅟ 的获取器。

itemLabelFormatChanged(format)
Parameters:

format – str

属性 itemLabelFormatᅟ 的通知信号。

itemLabelVisibleChanged(visible)
Parameters:

visible – 布尔值

属性 itemLabelVisibleᅟ 的通知信号。

mesh()
Return type:

Mesh

另请参阅

setMesh()

属性 meshᅟ 的获取器。

meshChanged(mesh)
Parameters:

网格Mesh

属性 meshᅟ 的通知信号。

meshRotation()
Return type:

QQuaternion

另请参阅

setMeshRotation()

属性 meshRotationᅟ 的获取器。

meshRotationChanged(rotation)
Parameters:

旋转QQuaternion

属性 meshRotationᅟ 的通知信号。

meshSmoothChanged(enabled)
Parameters:

enabled – 布尔值

属性 meshSmoothᅟ 的通知信号。

multiHighlightColor()
Return type:

QColor

属性 multiHighlightColorᅟ 的获取器。

multiHighlightColorChanged(color)
Parameters:

颜色QColor

属性 multiHighlightColorᅟ 的通知信号。

multiHighlightGradient()
Return type:

QLinearGradient

属性 multiHighlightGradientᅟ 的获取器。

multiHighlightGradientChanged(gradient)
Parameters:

渐变QLinearGradient

属性 multiHighlightGradientᅟ 的通知信号。

name()
Return type:

字符串

另请参阅

setName()

获取属性 nameᅟ 的Getter。

nameChanged(name)
Parameters:

name – str

属性 nameᅟ 的通知信号。

setBaseColor(color)
Parameters:

颜色QColor

另请参阅

baseColor()

属性 baseColorᅟ 的设置器。

setBaseGradient(gradient)
Parameters:

渐变QLinearGradient

另请参阅

baseGradient()

属性 baseGradientᅟ 的设置器。

setColorStyle(style)
Parameters:

styleColorStyle

另请参阅

colorStyle()

属性 colorStyleᅟ 的设置器。

setItemLabelFormat(format)
Parameters:

format – str

另请参阅

itemLabelFormat()

属性 itemLabelFormatᅟ 的设置器。

setItemLabelVisible(visible)
Parameters:

visible – 布尔值

另请参阅

isItemLabelVisible()

属性 itemLabelVisibleᅟ 的设置器。

setMesh(mesh)
Parameters:

网格Mesh

另请参阅

mesh()

属性 meshᅟ 的设置器。

setMeshAxisAndAngle(axis, angle)
Parameters:

一个方便的函数,用于从axisangle构造网格旋转四元数。

另请参阅

meshRotation

setMeshRotation(rotation)
Parameters:

旋转QQuaternion

另请参阅

meshRotation()

属性 meshRotationᅟ 的设置器。

setMeshSmooth(enable)
Parameters:

enable – 布尔值

另请参阅

isMeshSmooth()

属性 meshSmoothᅟ 的设置器。

setMultiHighlightColor(color)
Parameters:

颜色QColor

另请参阅

multiHighlightColor()

属性 multiHighlightColorᅟ 的设置器。

setMultiHighlightGradient(gradient)
Parameters:

渐变QLinearGradient

属性 multiHighlightGradientᅟ 的设置器。

setName(name)
Parameters:

name – str

另请参阅

name()

属性 nameᅟ 的设置器。

setSingleHighlightColor(color)
Parameters:

颜色QColor

另请参阅

singleHighlightColor()

属性 singleHighlightColorᅟ 的设置器。

setSingleHighlightGradient(gradient)
Parameters:

渐变QLinearGradient

属性 singleHighlightGradientᅟ 的设置器。

setUserDefinedMesh(fileName)
Parameters:

fileName – str

另请参阅

userDefinedMesh()

属性 userDefinedMeshᅟ 的设置器。

setVisible(visible)
Parameters:

visible – 布尔值

另请参阅

isVisible()

属性 visibleᅟ 的设置器。

singleHighlightColor()
Return type:

QColor

属性 singleHighlightColorᅟ 的获取器。

singleHighlightColorChanged(color)
Parameters:

颜色QColor

属性 singleHighlightColorᅟ 的通知信号。

singleHighlightGradient()
Return type:

QLinearGradient

属性 singleHighlightGradientᅟ 的获取器。

singleHighlightGradientChanged(gradient)
Parameters:

渐变QLinearGradient

属性 singleHighlightGradientᅟ 的通知信号。

type()
Return type:

SeriesType

属性 typeᅟ 的获取器。

userDefinedMesh()
Return type:

字符串

另请参阅

setUserDefinedMesh()

属性 userDefinedMeshᅟ 的获取器。

userDefinedMeshChanged(fileName)
Parameters:

fileName – str

属性 userDefinedMeshᅟ 的通知信号。

visibleChanged(visible)
Parameters:

visible – 布尔值

属性 visibleᅟ 的通知信号。