TooltipFormat

Definition of the formatting of the tooltips.

Schema: tchmi:framework#/definitions/Function

The selected function defines the tooltip display. It is called as soon as the mouse cursor is positioned on a point and/or an error. In addition, it contains the current timestamp of the mouse, which is specified in milliseconds, a list of points and a list of errors. The respective list is empty if there are no points or errors at this position.

A function must fulfill the following signature in order to be offered in the engineering. The parameters mentioned here are set by the control. Further parameters are possible and can be specified per instance in the engineering.

[ Function ]


TooltipFormat(actTime: number, points: TcHmiTrendLineChart.TooltipInformationObject[], errors: TcHmiTrendLineChart.TooltipErrorInformationObject[]): string;

Parameter

Name

Type

Description

actTime

number

The current timestamp of the mouse position in milliseconds since 1.1.1970.

points

TcHmiTrendLineChart.TooltipInformationObject[]

The recorded points locate (as array) at the mouse position (within the point radius).

errors

TcHmiTrendLineChart.TooltipErrorInformationObject[]

The recorded errors located (as array) at the mouse position.

Return value

Type

Description

string

The tooltip to be displayed. HTML is allowed here.

Origin: Trend Line Chart

See also

Attribute getter: getTooltipFormat

Attribute setter: setTooltipFormat

TooltipFormat 1:

Available from version 1.10