i have a pie chart where the legend's position is set to 'labeled', so the slice description and values are placed on a line next to the pie. What i want to do now is to change the color of the lines which connect the slices with the matching legend, to the color of the corresponding slice.
Is there any attribute in legend.textStyle or somewhere else which allows this change?
Here's my Code:
function drawVisualization() {
// Create and populate the data table.
var data = google.visualization.arrayToDataTable([
['Task', 'Hours per Day'],
['Work', 11],
['Eat', 2],
['Commute', 2],
['Watch TV', 2],
['Sleep', 7]
]);
// Create and draw the visualization.
new google.visualization.PieChart(document.getElementById('visualization')).
draw(data, {
width: '800',
height: '400',
title: "So, how was your day?",
legend: {
position: 'labeled',
textStyle: {
color: 'gray' // sets the text color
}
}
});
}
Thanks a lot!
Greetings, Andi