Bugs!

For discussion regarding the Eastwood Chart Servlet.

Bugs!

Postby nrap » Tue Jan 15, 2008 3:30 pm

As everything else new there are always bugs! :)

Suppose we need a pie chart with background color. If we set the background color for labels to i.e. cyan, and the background of the area to cyan as well, we shouldn't have anything in White color.

Check example here:
Code: Select all
chart.apis.google.com/chart?chf=bg,s,8ef1fd|c,s,8ef1fd&chco=b00404&chl=Local[14]|Long+Distance[122]|Vodafone[19]|Cosmote[45]|TIM[12]&chtt=Total+Calls+Count&cht=p&chs=600x300&chd=t:14,122,19,45,12

In our case, we see that everything changes into Cyan but the labels of the pie remain with white background.

Code: Select all
<local_server>/eastwood/chart?chf=bg,s,8ef1fd|c,s,8ef1fd&chco=b00404&chl=Local[14]|Long+Distance[122]|Vodafone[19]|Cosmote[45]|TIM[12]&chtt=Total+Calls+Count&cht=p&chs=600x300&chd=t:14,122,19,45,12

Still very happy with the result and the application though!!!
Keep up the good work. :D
nrap
 
Posts: 3
Joined: Tue Jan 15, 2008 3:24 pm

Postby nrap » Tue Jan 15, 2008 4:47 pm

Messy solution ( I'm only using PieCharts for now)

At ChartServlet.java line 793 add
Code: Select all
if (chart.getPlot() instanceof PiePlot3D) {
        ((PiePlot3D)chart.getPlot()).setLabelBackgroundPaint(c);
}else if (chart.getPlot() instanceof PiePlot) {
           ((PiePlot)chart.getPlot()).setLabelBackgroundPaint(c);
}
nrap
 
Posts: 3
Joined: Tue Jan 15, 2008 3:24 pm

Postby david.gilbert » Tue Jan 15, 2008 4:56 pm

Thanks for the report. I've added this to the bug tracker:

http://sourceforge.net/tracker/index.ph ... id=1022207

I didn't look at this closely yet, but maybe setting the label background paint to null is a good solution?
David Gilbert
JFreeChart Project Leader

:idea: Read my blog
:idea: Ask your company to buy the JFreeChart Developer Guide
:idea: Check out other products sold by my company Object Refinery Limited
david.gilbert
JFreeChart Project Leader
 
Posts: 11316
Joined: Fri Mar 14, 2003 10:29 am

Postby nrap » Wed Jan 16, 2008 8:32 am

Look at that...
It is a good solution (and much simpler than mine!)
thanx!
nrap
 
Posts: 3
Joined: Tue Jan 15, 2008 3:24 pm


Return to Eastwood Chart Servlet

Who is online

Users browsing this forum: Bing [Bot] and 0 guests