HTMLcopy
1
<div id="container"></div>
CSScopy
6
1
html, body, #container {
2
width: 100%;
3
height: 100%;
4
margin: 0;
5
padding: 0;
6
}
JavaScriptcopy
x
1
anychart.onDocumentReady(function () {
2
var chart = anychart.column3d([
3
{x: 'Meat', value: 10},
4
{x: 'Fruit', value: 12},
5
{x: 'Nuts', value: 18},
6
{x: 'Milk', value: 11},
7
{x: 'Fish', value: 5}
8
]);
9
10
// Get tooltip.
11
var tooltip = chart.tooltip();
12
13
tooltip.enabled(true);
14
tooltip.fontColor('#ee3b3b');
15
tooltip.fontWeight(600);
16
tooltip.background('#76ee00');
17
18
chart.title('Get and modify chart tooltip');
19
chart.container('container');
20
chart.draw();
21
});