View Full Version : ExtJS 4 Smart legend extension, how to restrict width of legend

22 Oct 2012, 11:04 PM
I'm using Smart legend extension to break the legend into 2 columns if too many categories are in.

But some legend have really lengthy text which will cause the legend to take up too much space and cause the chart to render really small. Is there any way to fix this issue?

25 Oct 2012, 6:03 AM
That is a commercial product and you should then try to get support from the author

29 Apr 2013, 4:26 AM
please help me,
My code Like this

me.chart = new Ext.create('Ext.chart.Chart', {
width: me.width, height: me.height,
store: chartStore, animate: me.animate,
shadow: me.shadow,
legend: true,
backGround: me.backGround,
axes: me.axes, series: me.series

legend = me.chart.legend = new Ext.create('Ext.ux.chart.SmartLegend', {
position: 'bottom',
chart: me.chart,
rebuild: true,
boxStrokeWidth: 1


then it give me error of

Microsoft JScript runtime error: Unable to get value of the property 'add': object is null or undefined

on this line

box = me.boxSprite = me.chart.surface.add(Ext.apply({ . .

of ext-all-debug.js file:-/