Hi out there,
I googled and searched within here a lot, but I did not find anything concerning an automated shape scaling when zooming will be performed.
Thus, I assume, JFreeChart is not capable of doing that, right?
If so, if I would like to implement this, how would I have to do best?
Remark, I use XYLineAndShapeRenderes -> should I scale my figures manually when zooming will be performed?
Or would there be a more elegant solution?
Thanks in advance,
Tobias
Automatic shape scaling when zooming?
-
- Posts: 14
- Joined: Fri Nov 02, 2007 8:21 am
Re: Automatic shape scaling when zooming?
Good topic



-
- JFreeChart Project Leader
- Posts: 11734
- Joined: Fri Mar 14, 2003 10:29 am
- antibot: No, of course not.
- Contact:
It isn't supported directly, but it is a relatively straightforward modification. In the XYLineAndShapeRenderer class, you could scale the shape (just prior to translating it) in the drawSecondaryPass() method. The only trick is how to determine the scaling factor (you'd need to store the "default" bounds of the x and y axis where there is no scaling, and then look at the current bounds to determine the scaling factor).
David Gilbert
JFreeChart Project Leader
Read my blog
Support JFree via the Github sponsorship program
JFreeChart Project Leader


Modify the domain scale on a XYChart
Hi there,
I'm kinda confused reading previous posts, so I'll put my question here:
I have a XYSeries chart and because of the user requirements, I need to add to a swing application a couple of spinners that modifies both vertical and horizontal scales of the Chart.
The main issue is that I don't know if that's possible with JFreeChart.
I'll really appreciate any help.
Thanks in advance.
I'm kinda confused reading previous posts, so I'll put my question here:
I have a XYSeries chart and because of the user requirements, I need to add to a swing application a couple of spinners that modifies both vertical and horizontal scales of the Chart.
The main issue is that I don't know if that's possible with JFreeChart.
I'll really appreciate any help.
Thanks in advance.
efmcuiti