QHBoxPlotModelMapper 类
QHBoxPlotModelMapper 类是箱线图系列的横向模型映射器。 更多...
| 头文件 | #include <QHBoxPlotModelMapper> | 
| 由以下类实例化 | HBoxPlotModelMapper | 
| 继承自 | QObject | 
属性
| 
 | 
 | 
公共函数
| QHBoxPlotModelMapper(QObject *parent = nullptr) | |
| int | columnCount() const | 
| int | firstBoxSetRow() const | 
| int | firstColumn() const | 
| int | lastBoxSetRow() const | 
| QAbstractItemModel * | model() const | 
| QBoxPlotSeries * | series() const | 
| void | setColumnCount(int rowCount) | 
| void | setFirstBoxSetRow(int firstBoxSetRow) | 
| void | setFirstColumn(int firstColumn) | 
| void | setLastBoxSetRow(int lastBoxSetRow) | 
| void | setModel(QAbstractItemModel *model) | 
| void | setSeries(QBoxPlotSeries *series) | 
信号
| void | columnCountChanged() | 
| void | firstBoxSetRowChanged() | 
| void | firstColumnChanged() | 
| void | lastBoxSetRowChanged() | 
| void | modelReplaced() | 
| void | seriesReplaced() | 
详细描述
模型映射器允许使用从 QAbstractItemModel 类派生出的数据模型作为图表的数据源。横向模型映射器用于在数据模型和 QBoxPlotSeries 对象之间建立连接,因此数据模型中的每一行定义一个箱线和须项,每一列映射到箱线和须项的范围和三个中位数。
可以使用模型和系列属性来操纵数据。模型映射器将系列和数据模型保持同步。
模型映射器确保箱线图中所有的盒须项具有相同的大小。因此,对一个盒须项添加或移除值将导致箱线图中所有盒须项发生相同的更改。
另请参阅 QVBoxPlotModelMapper.
属性文档
columnCount : int
此属性包含模型中映射为箱线图系列数据的列数。
最小和默认值是 -1(限制模型的列数)。
访问函数
| int | columnCount() const | 
| void | setColumnCount(int rowCount) | 
通知信号
| void | columnCountChanged() | 
firstBoxSetRow : int
此属性包含用作第一个盒须项数据源模型的行。
默认值是 -1(无效映射)。
访问函数
| int | firstBoxSetRow() const | 
| void | setFirstBoxSetRow(int firstBoxSetRow) | 
通知信号
| void | firstBoxSetRowChanged() | 
firstColumn : int
此属性包含包含箱线图系列中盒须项第一个值的模型的列。
最小和默认值是 0。
访问函数
| int | firstColumn() const | 
| void | setFirstColumn(int firstColumn) | 
通知信号
| void | firstColumnChanged() | 
lastBoxSetRow : int
此属性包含用作最后一个盒须项数据源模型的行。
默认值是 -1(无效映射)。
访问函数
| int | lastBoxSetRow() const | 
| void | setLastBoxSetRow(int lastBoxSetRow) | 
通知信号
| void | lastBoxSetRowChanged() | 
model : QAbstractItemModel*
此属性包含映射器使用的模型。
访问函数
| QAbstractItemModel * | model() const | 
| void | setModel(QAbstractItemModel *model) | 
通知信号
| void | modelReplaced() | 
series : QBoxPlotSeries*
此属性包含映射器使用的箱线图系列。
当设置为映射器时,系列中的所有数据都将被丢弃。当指定新系列时,旧系列将断开连接(但保留其数据)。
访问函数
| QBoxPlotSeries * | series() const | 
| void | setSeries(QBoxPlotSeries *series) | 
通知信号
| void | seriesReplaced() | 
成员函数文档
[显式] QHBoxPlotModelMapper::QHBoxPlotModelMapper(QObject *parent = nullptr)
构建一个作为parent子对象的消息传递器对象。
[信号] void QHBoxPlotModelMapper::columnCountChanged()
当列数更改时发出此信号。
注意:属性columnCount的通知信号。
[信号] void QHBoxPlotModelMapper::firstBoxSetRowChanged()
当第一个盒须项行更改时发出此信号。
注意:属性firstBoxSetRow的通知信号。
[信号] void QHBoxPlotModelMapper::firstColumnChanged()
当第一列更改时发出此信号。
注意:属性 firstColumn 的通知信号。
[信号] void QHBoxPlotModelMapper::lastBoxSetRowChanged()
当最后的一个箱型图项行变更时,发出此信号。
注意:属性 lastBoxSetRow 的通知信号。
[信号] void QHBoxPlotModelMapper::modelReplaced()
当映射器连接的模型变化时,发出此信号。
注意:属性 model 的通知信号。
[信号] void QHBoxPlotModelMapper::seriesReplaced()
当映射器连接的序列变化时,发出此信号。
注意:属性 series 的通知信号。
© 2024 The Qt Company Ltd. 文档贡献者的权利属于各自的拥有者。所提供的文档是根据《GNU自由文档许可协议版本1.3》许可,由自由软件基金会发布。Qt及其相关标志是The Qt Company Ltd. 在芬兰和/或其他国家的商标。所有其他商标均为其各自所有者的财产。