AbstractSeries QML Type
所有 Qt Graph 系列类型的基础类型。更多
Import Statement: | import QtGraphs |
In C++: | QAbstractSeries |
Inherited By: | AreaSeries, BarSeries, PieSeries, and XYSeries |
- 所有成员的列表,包括继承成员
- AbstractSeries 是Qt Graphs QML Types for 2D 的一部分。
属性
- hoverable : bool
- legendData : list<LegendData>
- name : string
- opacity : real
- selectable : bool
- type : enumeration
- valuesMultiplier : real
- visible : bool
信号
- hoverableChanged()
- legendDataChanged()
- nameChanged()
- opacityChanged()
- selectableChanged()
- themeChanged()
- valuesMultiplierChanged()
- visibleChanged()
详细说明
该类型不能直接实例化。相反,应使用以下派生类型之一来创建系列:LineSeries,SplineSeries,BarSeries, 或ScatterSeries 。
属性文档
hoverable : bool |
控制是否可以用鼠标/触摸悬停系列。默认情况下,hoverable 设置为false
。
legendData : list<LegendData> |
包含为图表中的数据集创建图例标记所需的信息。
name : string |
系列名称。该名称将显示在序列的图例中,并支持 HTML 格式。
opacity : real |
系列的不透明度。默认情况下,不透明度为 1.0。有效值范围从 0.0(透明)到 1.0(不透明)。
selectable : bool |
控制是否可以用鼠标/触摸选择系列。默认情况下,selectable 设置为false
。
type : enumeration |
系列类型。
常数 | 描述 |
---|---|
AbstractSeries.SeriesType.Line | 折线图。 |
AbstractSeries.SeriesType.Bar | 条形图 |
AbstractSeries.SeriesType.Scatter | 散点图 |
AbstractSeries.SeriesType.Pie | 饼图 |
AbstractSeries.SeriesType.Spline | 曲线图 |
AbstractSeries.SeriesType.Area | 面积图 |
valuesMultiplier : real |
该变量可用于动画系列值,使其从 0 缩放至实际值大小。默认情况下,valuesMultiplier 为 1.0。有效值范围从 0.0(高度为 0)到 1.0(满值)。
visible : bool |
该系列使用的可见性。默认情况下,visible 设置为true
。
信号文档
hoverableChanged() |
该信号在hoverable 系列发生变化时发出。
注: 相应的处理程序是onHoverableChanged
。
legendDataChanged() |
图例数据更改时发出此信号。
注: 相应的处理程序是onLegendDataChanged
。
nameChanged() |
当name 系列发生变化时,将发出此信号。
注: 相应的处理程序是onNameChanged
。
opacityChanged() |
当opacity 系列发生变化时,将发出此信号。
注: 相应的处理程序是onOpacityChanged
。
selectableChanged() |
当系列selectable 发生变化时,发出此信号。
注: 相应的处理程序是onSelectableChanged
。
themeChanged() |
当系列主题发生变化时,发出此信号。
注: 相应的处理程序是onThemeChanged
。
valuesMultiplierChanged() |
当valuesMultiplier 系列发生变化时,会发出该信号。
注: 相应的处理程序是onValuesMultiplierChanged
。
visibleChanged() |
系列可见性发生变化时,发出此信号。
注: 相应的处理程序是onVisibleChanged
。
© 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.