Axes Spacing

A discussion forum for JFreeChart (a 2D chart library for the Java platform).
Locked
tox0tes
Posts: 34
Joined: Tue Aug 05, 2008 7:05 pm

Axes Spacing

Post by tox0tes » Thu Aug 28, 2008 10:10 pm

How do I control the spacing between multiple axes? Also, how do I control the color of the tick marks and tick vertical line (the gray) of each axis. Look at picture for reference:

Image

david.gilbert
JFreeChart Project Leader
Posts: 11734
Joined: Fri Mar 14, 2003 10:29 am
antibot: No, of course not.
Contact:

Post by david.gilbert » Fri Aug 29, 2008 6:47 am

One way to change the spacing is to call the setLabelInsets() method on each axis. This only changes the spacing around the axis label, but that does also affect the position of the next axis drawn.

And setTickMarkPaint() and setAxisLinePaint() will control the colour of the axis line and tick marks.
David Gilbert
JFreeChart Project Leader

:idea: Read my blog
:idea: Support JFree via the Github sponsorship program

tox0tes
Posts: 34
Joined: Tue Aug 05, 2008 7:05 pm

Post by tox0tes » Fri Aug 29, 2008 10:01 pm

the color methods worked, but the RectangleInsets method caused the axes to go off the screen due to the main chart not updating with the new width. This is probably a bug. I can post a picture if you don't know what I mean.

Locked