ChartArea.getTooltipLayer

Syntax

getTooltipLayer();

Description

The getTooltipLayer method gets SVG object used to draw tooltip layer.

Comments

This method returns a value of the SVGElement type.

Example

To execute this example, the HTML page must contain the BubbleChart component named bubbleChart (see Example of Creating the BubbleChart Component). Get SVG element used to draw tooltip layer, get its parent container and output its sizes:

// Get bubble chart area
var chartArea = bubbleChart.getChartArea();
// Get SVG element used to render tooltip layer
var tooltipLayer = chartArea.getTooltipLayer();
// Get parent container of tooltip container
var parent = tooltipLayer.parentNode;
// Output parent container sizes
console.log("Sizes of parent container of tooltip layer: " + parent.clientWidth + "x" + parent.clientHeight);

After the example execution the browser console shows size of parent container for SVG element used to draw tooltip layer:

Sizes of parent container for tooltip layer: 500x243

See also:

ChartArea