with setValueLabelsVisible not all values displayed ...

A discussion forum for JFreeChart (a 2D chart library for the Java platform).
Locked
Matthias Suttner

with setValueLabelsVisible not all values displayed ...

Post by Matthias Suttner » Thu Mar 06, 2003 4:19 pm

'cause there is not enough space between bar and the top of the chart.

Knows anyone a solutions?

I've the same problem like this
http://www.object-refinery.com/jfreecha ... line_1.png


thx
Matthias

David Gilbert

Re: with setValueLabelsVisible not all values displayed ...

Post by David Gilbert » Thu Mar 06, 2003 5:31 pm

Hi Matthias,

Unfortunately the auto-range calculation for the axis doesn't know about the value labels, so it doesn't allow any extra room for them. All you can do is manually increase the upper margin for the axis:

ValueAxis axis = myPlot.getRangeAxis();
axis.setUpperMargin(0.10); // ten percent

Regards,

Dave Gilbert

Matthias Suttner

Re: with setValueLabelsVisible not all values displayed ...

Post by Matthias Suttner » Fri Mar 07, 2003 8:01 am

Thanks David,

i will try that


bye
Matthias


David Gilbert wrote:
>
> Hi Matthias,
>
> Unfortunately the auto-range calculation for the axis doesn't
> know about the value labels, so it doesn't allow any extra
> room for them. All you can do is manually increase the upper
> margin for the axis:
>
> ValueAxis axis = myPlot.getRangeAxis();
> axis.setUpperMargin(0.10); // ten percent
>
> Regards,
>
> Dave Gilbert

Locked