- class QCandlestickModelMapper#
蜡烛图系列的抽象模型映射类。更多信息…
继承自:
QVCandlestickModelMapper,QHCandlestickModelMapper摘要#
属性#
方法#
def
__init__()def
close()def
high()def
lastSetSection()def
low()def
model()def
open()def
series()def
setClose()def
setHigh()def
setLow()def
setModel()def
setOpen()def
setSeries()def
setTimestamp()def
timestamp()
虚方法#
def
orientation()
信号#
注意
此文档可能包含从 C++ 自动翻译到 Python 的代码片段。我们始终欢迎对代码片段进行翻译的贡献。如果您发现翻译有误,您也可以通过在 https:/bugreports.qt.io/projects/PYSIDE 创建工单的方式告知我们。
详细描述#
模型映射器允许将 QAbstractItemModel 派生的模型作为图表系列的数据源使用,在
QCandlestickSeries和模型对象之间创建连接。模型映射器保持所有QCandlestickSets的大小相等。注意
所使用的模型必须支持添加和删除行/列以及修改单元格的数据。
注意
可以使用属性(当使用
from __feature__ import true_property时)或通过访问器函数来使用属性。- property modelᅟ: QAbstractItemModel#
此属性定义由映射器使用的模型。
- 访问函数
- property seriesᅟ: QCandlestickSeries#
此属性定义由映射器使用的
QCandlestickSeries对象。注意
当将其设置为映射器时,将丢弃系列中的所有数据。当指定新的系列时,将断开旧系列的连接(保留其数据)。
- 访问函数
构造一个模型映射器对象,作为
parent的子对象。- close()#
- 返回类型:
int
返回包含系列中集合接近值的模型行/列。默认值为 -1(无效映射)。
另见
- firstSetSection()#
- 返回类型:
int
返回作为第一个蜡烛图集数据源的模型部分。默认值是 -1(无效映射)。
- high()#
- 返回类型:
int
返回包含系列中集合高值的模型行/列。默认值是 -1(无效映射)。
另见
- lastSetSection()#
- 返回类型:
int
返回作为最后一个蜡烛图集数据源的模型部分。默认值是 -1(无效映射)。
- low()#
- 返回类型:
int
返回包含系列中集合低值的模型行/列。默认值是 -1(无效映射)。
另见
- model()#
- 返回类型:
另见
属性
modelᅟ的获取器。- modelReplaced()#
当与映射器连接的模型更改时发出。
另见
属性
modelᅟ的通知信号。- open()#
- 返回类型:
int
返回包含系列中集合开放值的模型行/列。默认值是 -1(无效映射)。
另见
当
QCandlestickModelMapper访问模型时使用的方向。这决定了集合的连续值是从行(Qt::Horizontal)还是从列(Qt::Vertical)读取的。- series()#
- 返回类型:
另见
属性
seriesᅟ的获取器。- seriesReplaced()#
当与映射器连接的系列更改时发出。
另见
属性
seriesᅟ的通知信号。- setClose(close)#
- 参数:
close – int
设置模型中包含系列集中闭合值的行/列。默认值为-1(无效映射)。
另见
- setFirstSetSection(firstSetSection)#
- 参数:
firstSetSection – int
设置作为第一根蜡烛图集中数据源的模型部分。参数
firstSetSection指定模型的部分。默认值为-1。- setHigh(high)#
- 参数:
high – int
设置模型中包含系列集中最高值行/列。默认值为-1(无效映射)。
另见
- setLastSetSection(lastSetSection)#
- 参数:
lastSetSection – int
设置作为最后根蜡烛图集中数据源的模型部分。参数
lastSetSection指定模型的部分。默认值为-1。- setLow(low)#
- 参数:
low – int
设置模型中包含系列集中最低值行/列。默认值为-1(无效映射)。
另见
- setModel(model)#
- 参数:
model –
QAbstractItemModel
另见
属性
modelᅟ的设置器。- setOpen(open)#
- 参数:
open – int
设置模型中包含系列集中开盘值行/列。默认值为-1(无效映射)。
另见
- setSeries(series)#
- 参数:
series –
QCandlestickSeries
另见
属性
seriesᅟ的设置器。- setTimestamp(timestamp)#
- 参数:
timestamp – int
设置包含系列中集合的时间戳值的模型的行/列。默认值是-1(无效映射)。
另见
- timestamp()#
- 返回类型:
int
返回包含系列中集合时间戳值的模型的行/列。默认值是-1(无效映射)。