17 Jan 2012 7:07 AM #1
Adding a Chart title within the chart area
I'm using the SVG generated by the chart class to generate images on the server.
var svgCode = Ext.getCmp('chart_' + win.id).getEl().dom.innerHTML;
Ideally I'd like the chart title inside the chart so that the title appears in the SVG and therefore in the image.
I've tried using a text sprite to place a title on the chart, but this can obscure the chart lines/bars.
Ideally I'd like to create some dead space above the chart (but part of the chart), into which I can place the sprite, and therefore have it preserved in the SVG and the images.
The other idea I had was to position the legend on top and try to add the title as the first item to the legend, but I cannot find a method to insert items into a legend.
Does anyone have any suggestions ?