Box
Map

JavaScript/jQuery Chart - crosshair.horizontalLine.label

Configures the label that belongs to the horizontal crosshair line.

Type:

Object

Crosshair labels can be configured using the following objects.

  • crosshair.horizontalLine.label
    Configures the label of the horizontal crosshair line only.

  • crosshair.verticalLine.label
    Configures the label of the vertical crosshair line only.

  • crosshair.label
    Configures both the labels.

These objects have identical structure, but the label settings declared in the horizontalLine or verticalLine object override the label settings declared directly in the crosshair object.

See Also
  • crosshair.verticalLine.label - configures the label that belongs to the vertical crosshair line.

backgroundColor

Paints the background of the label that belongs to the horizontal crosshair line.

Type:

String

Default Value: '#f05b41'

This property supports the following colors:

customizeText

Customizes the text displayed by the label that belongs to the horizontal crosshair line.

Type:

Function

Function parameters:
info:

Object

Information about the point a user paused on.

Object structure:
Name Type Description
point

Point

The Point object.

value

Date

|

Number

|

String

The raw point value.

valueText

String

The formatted value converted to a string.

Return Value:

String

The text to be displayed in the label that belongs to the horizontal crosshair line.

Cannot be used in themes.

NOTE
As an alternative to the function’s parameter you can use the this keyword.

font

Specifies font properties for the label of the horizontal crosshair line.

Type:

Object

format

Formats a point value before it is displayed in the crosshair label.

Type:

Format

Default Value: undefined

See the format section for information on accepted values.

When this property value is undefined, the date-time axes display larger date range boundaries in labels. For example, if an axis displays months, it also displays a year near each instance of January. If an axis displays days, it also displays a month name near each first visible day mark.

See Also

visible

Makes the label of the horizontal crosshair line visible. Applies only if the crosshair feature is enabled and the horizontal line is visible.

Type:

Boolean

Default Value: false