Reputation: 822
I am using angular-highcharts
, in this we have options like addSeries(), removeSeries(), addPoint()
etc. but nothing like add height and width.
In angular-highchart
, there are some issues that if I'm working with widgets
having full screen option. When the widget goes fullscreen
inside which the highchart
is there, the highchart
doesn't take the parent height and width i.e. Widget's height and width.
Normally, I can give height and width like this:
chart:{
type:'bar',
height:600,
width:1450
},
So, is there any solution that how I can add height and width dynamically in highcharts
.
Upvotes: 1
Views: 2368
Reputation: 571
there is no setHeight or setWidth but there is a setSize:
setSize( [width] [, height] [, animation]). Example:
chart.setSize(chartWidth, chartHeight);
here is an jsfiddle testing setSize
also there is an 'update' function where you can update almost every option of the chart, here is an jsfiddle showing how:
Upvotes: 1