Skip to content

Tooltip

Thomas Möller edited this page Apr 12, 2024 · 21 revisions

Class name

Tooltip

Purpose / Description

This class contains methods and properties related to the tooltip.

Methods

  • none

Properties


Detailed description

The following sections contain a detailed description of the methods and properties.

BackgroundColor

Description:

With this property you can specify the color of the background of the tooltip.

You can specify the background color in four ways:

  • rgba-code: rgba(77,22,66,0.5)
  • rgb-code: rgb(128,255,73)
  • hex-code: #FF77A1
  • color name: green

Default value:

--

Sample code:

myChart.Chart.Tooltip.BackgroundColor = "grey"

Related to:

BorderWidth

BorderColor

Description:

With this property you can specify the color of the border of the tooltip.

You can specify the background color in four ways:

  • rgba-code: rgba(77,22,66,0.5)
  • rgb-code: rgb(128,255,73)
  • hex-code: #FF77A1
  • color name: green

Default value:

{nothing} which leads to 'rgba(0, 0, 0, 0)'

Sample code:

myChart.Chart.Tooltip.BorderColor = "red"

Related to:

BorderWidth

BorderWidth

Description:

With this property you can specify the size of the border of the tooltip.

Default value:

0

Sample code:

myChart.Chart.Tooltip.BorderWidth = 2

Related to:

BorderColor

CaretSize

Description:

With this property you can specify the size, in px, of the tooltip arrow.

Default value:

5

Sample code:

myChart.Chart.Tooltip.CaretSize = 10

Related to:

CaretPadding

CaretPadding

Description:

With this property you can specify the extra distance to move the end of the tooltip arrow away from the tooltip point.

Default value:

2

Sample code:

myChart.Chart.Tooltip.CaretPadding = 5

Related to:

CaretSize

DisplayColors

Description:

With this property you can specify if color boxes are shown in the tooltip.

Default value:

True

Sample code:

myChart.Chart.Tooltip.DisplayColors= False

Related to:

UsePointStyle

Enabled

Description:

With this property you can specify if the tooltip is enabled.

Default value:

True

Sample code:

myChart.Chart.Tooltip.Enabled = False

Related to:

--

Padding

Description:

With this property you can specify the padding inside the tooltip.

Default value:

6

Sample code:

myChart.Chart.Tooltip.Padding = 10

Related to:

--

Position

Description:

With this property you can specify the mode for positioning the tooltip.

Possible values:

  • ttpAverage
  • ttpNearest

Default value:

ttpAverage

Sample code:

myChart.Chart.Tooltip.Position = ttpNearest

Related to:

--

UsePointStyle

Description:

With this property you can specify to use the corresponding point style instead of color boxes.

This property only has an effect if "DisplayColors" is set to "True".

Default value:

False

Sample code:

myChart.Chart.Tooltip.UsePointStyle = True

Related to:

DisplayColors