01 | { |
02 | settings: { |
03 | tooltipSettings: { |
04 | enabled: true |
05 | } |
06 | } |
07 | } |
Unlike Grouped - Separated tooltip is the type that shows one tooltip for each series shown on the chart. Its configuration is in many ways similar to the one of Grouped tooltip, but there is a lot of special options and display modes.
This article describes all the available display modes and explains how to configure them.
To enable/disable tooltips, you need to use the enabled attribute of the <tooltip_settings> node. You can enable/disable tooltips for all charts, some of the charts, some of the series types or some of the series, as it is described in the Tooltip Settings section.
Here is a sample XML for enabling tooltips on all charts:
To use Separated tooltips, you need to set the tooltip_mode attribute to "Separated":
Separated tooltips show one tooltip for each series, and there are three ways to doing that:
The samples and configuration for all the modes are given below.
Showing all tooltips on all charts in the separated mode is reasonable when you have a relatively small number of series shown and want to highlight all the available values:
To activate this mode, you need to specify it in the display_mode attribute of the <tooltip_settings> node:
Live Sample for a chart with tooltips in the "Show Separated Tooltips - All Charts" mode:
If you have several charts with a relatively small number of series shown on each of them, you may want to choose displaying Separated tooltips for the Current Chart only:
To activate this mode, you need to specify it in the display_mode attribute of the <tooltip_settings> node:
Live Sample of a chart with tooltips in the "Show Separated Tooltips - Current Chart Only " mode:
When there is a lot of series shown on the chart, you may want to show a tooltip only when user points on some point of one of the series with the mouse:
To enable this mode, you need set the special affects attribute of the <separated_tooltip> node to "CurrentSeries":
Live Sample of a chart with tooltips in the "Show Separated Tooltips - Hovered Point Only " mode:
Separated tooltips are always configured in the <separated_tooltip> subnode of the <tooltip_settings> node. This node has a lot of configuration options, which are described in detail in Separate Tutorials.
The main thing we want to highlight in this section is that a tooltip can be configured in several places and, depending on the task, you can choose any of them.
You can configure all the tooltip options for a given series in the series list; for example, to change the format of the text for a selected series, you would need to use the following XML:
In the sample below, the two series have an individual format defined for each of them, and the third series has no tooltip at all, as tooltips are disabled for that series:
When you use several types of series on one chart, it may happen that the series of a given type have typical tooltip settings; in this case, you can define the defaults for this series type. To do that, you need, for example, to make the following settings:
As you can see here, these settings define that the separated tooltips for the area series and line series should have different background and font settings.
The live sample below shows a sample chart with such settings in action:
You can configure all the tooltips on a chart one standard way:
Please note: Setting anything on this level doesn't cancel the settings on the levels described above. In the live sample below we use series type settings, individual series settings and chart defaults at the same time:
And another level higher, where you can configure all the tooltips on all the charts:
Please note: Setting anything on this level doesn't cancel the settings on the levels described above. In the live sample below we combine the settings again:
To find out how to configure a tooltip element's text and visual settings and layout, please refer to: