When I create charts within a servlet and pump them back as JPEGs, there is a single pixel border around the chart by default.
Is there any way to get rid of this?
:L
Border around a chart
Re: Border around a chart
chart.getXYPlot.setInsets(new Insets(0,0,0,0));
that might do it.
that might do it.
Re: Border around a chart
1/4 of the way there -- it removed the 'right' hand border.

Any more ideas?
Thanks,
:L

Any more ideas?
Thanks,
:L
Re: Border around a chart
Hi Laurence,
Can you e-mail me a copy of your image file, and I'll look into where the border comes from. It depends on whether or not you have titles, a legend, axes etc.
Regards,
DG
Can you e-mail me a copy of your image file, and I'll look into where the border comes from. It depends on whether or not you have titles, a legend, axes etc.
Regards,
DG
Re: Border around a chart
Check out the article that I published -- that servlet produces them...
:L
:L
Re: Border around a chart
If not too late, this worked for me : tplot.setInsets(new Insets(-1, -1, -1, -1));
Somehow, the top border needs a -1, not 0.
Somehow, the top border needs a -1, not 0.