I wonder If Google Charts API provide options to resize the Chart element? Or is there any workaround for that?
Asked
Active
Viewed 164 times
0
-
1http://stackoverflow.com/questions/8950761/google-chart-redraw-scale-with-window-resize – jterry Jun 20 '13 at 12:09
-
@jterry thanks for the link. I read that before posting. not sure Iam duplicating it. Mine doesn't actually involve window resize. just a control that allows resize. e.g. Chrome textarea – Njax3SmmM2x2a0Zf7Hpd Jun 20 '13 at 15:22
1 Answers
1
Per your comment -- you could augment the solution in this answer by tapping into jQuery
's resize
method:
$('#your_element_id').resize(function() {
var chart = new google.visualization.LineChart(document.getElementById('chart_div'));
chart.draw(data, options);
}
I'm assuming that the answer in the previous question is valid, but it's accepted so it likely is :)