NumericLabelProvider

StockSharp.Xaml.Charting.Visuals.Axes

NumericLabelFormatter是使用 TextFormatting 和 CursorTextFormatting 属性来格式化轴和光标标签文本的通关

继承自: LabelProviderBase

方法

CreateDataContext
public override ITickLabelViewModel CreateDataContext(IComparable dataValue)
result = numericLabelProvider.CreateDataContext(dataValue)

创建基于数据传递值的 ITickLabelViewModel 实例。 Invokes IComparable 用于格式化指定数据传递值。

dataValue
数据值到格式
FormatCursorLabel
public override string FormatCursorLabel(IComparable dataValue, bool hitTest)
result = numericLabelProvider.FormatCursorLabel(dataValue, hitTest)

格式化光标的标签,从指定的数据值中转出

dataValue
数据值到格式
hitTest
克克击出试.

返回值: 格式化光标标签字符串

FormatLabel
public override string FormatLabel(IComparable dataValue)
result = numericLabelProvider.FormatLabel(dataValue)

格式化从指定的数据值中传递到的轴的标签

dataValue
数据值到格式

返回值: 格式化标签字符串

UpdateDataContext
public override ITickLabelViewModel UpdateDataContext(ITickLabelViewModel labelDataContext, IComparable dataValue)
result = numericLabelProvider.UpdateDataContext(labelDataContext, dataValue)

根据传输的数据值更新现有的 ITickLabelViewModel。 Invokes IComparable 以格式化传输的数据值。

labelDataContext
需要更新的例子
dataValue
数据值到格式