Forum /
Ext JS Community Forums 3.x /
Ext 3.x: Help & Discussion /
Pie Chart - how to customize legend text
Pie Chart - how to customize legend text
Hello,
I'm trying to customize the display text on the legend of a pie chart.
The default legend will display the 'categoryField'.
Is there anyway I can customize it so that it swill display 'categoryField . dataField'?
Thanks.
Sencha - Community Support Team
Look at the source of this example from CH9 of my book: http://extjsinaction.com/examples/ch..._PieChart.html
Hello Jay Garcia,
Thanks a lot for the example.
I can see from the code how you do the custom tiprenderer function.
What I really need is to know how customize the legend text:
e.g. 20,000's to 20,000's (42)
Sencha - Community Support Team
Write a legendRenderer instead of tipRenderer?
My question is, is there a legendRenderer item for the chart?
I tried writing a legendRenderer function instead of tipRenderer, but it doesn't work.
var pieChart = {
xtype : 'piechart',
id : 'empPieChart',
store : pieStore,
dataField : 'total',
categoryField : 'range',
tipRenderer : tipRenderer,
legendRenderer : legendRenderer
}
Sencha User
Anyone figure this out yet? I had a request to add the totals to the category in the legend. I looked at the example cited, but couldn't see how that would alter the legend.
I'm looking for a solution to this question as well...
Sadly I've given up on this. I've searched everywhere and I don't think that it is possible.
Well if you do find the solution please post it here.
Has anybody got the answer for the Legend Renderer...as I'm also lookin for the same...please help if u hav any soln.
Similar Threads
By dave26540 in forum Ext 3.x: Help & Discussion
Replies: 4
Last Post: 2 Dec 2012, 10:25 PM
By razwan in forum Ext 3.x: Help & Discussion
Replies: 1
Last Post: 25 Nov 2009, 4:33 AM
By e-tip in forum Ext 3.x: Help & Discussion
Replies: 0
Last Post: 24 Nov 2009, 7:12 AM
Tags for this Thread
Sencha is used by over two million developers. Join the community, wherever you’d like that community to be
or Join Us