JFreeChart Pan

A discussion forum for JFreeChart (a 2D chart library for the Java platform).
Locked
mariapazabalza
Posts: 2
Joined: Thu Nov 23, 2017 11:26 am
antibot: No, of course not.

JFreeChart Pan

Post by mariapazabalza » Thu Nov 23, 2017 11:32 am

Hi,

Im doing a interactive ChartPanel, I would like to insert the Pan functionality and I found your class: PanHandler, but when I created the class, Java told me: AbstractMouseHandler cannot be resolved to a type.
I dont know what happens, I downloaded the last jar version.
Could you tell me what happens?, or if there is another way to develop Pan functionality .
Thanks

John Matthews
Posts: 513
Joined: Wed Sep 12, 2007 3:18 pm

Re: JFreeChart Pan

Post by John Matthews » Thu Nov 23, 2017 2:50 pm

XYPlot implements Pannable, and it offers methods to control panning for either the domain or range: setDomainPannable() and setRangePannable().

mariapazabalza
Posts: 2
Joined: Thu Nov 23, 2017 11:26 am
antibot: No, of course not.

Re: JFreeChart Pan

Post by mariapazabalza » Fri Nov 24, 2017 9:06 am

Thanks,
I found a folder called pan_patch3 where they are implemented two methods for zooming and planning, but the second one doesnt work as I want.
I downloaded another script PanHandler but I cant use because I dont have AbstractMouseHandler, I dont understand anything, I would like to be able to plan in a similar way than Matlab.

paradoxoff
Posts: 1634
Joined: Sat Feb 17, 2007 1:51 pm

Re: JFreeChart Pan

Post by paradoxoff » Fri Nov 24, 2017 11:53 am

I think that you may have accidentally mixed two different version.
The classes PanHandler and AbstractMouseHandler are part of the FSE (future state edition) of JFreeChart, and they are missing in the most recent "regular" JFreeChart version (1.5.0).
Instead of downloading patches and scripts from an unspecified location, you should try to stick to one version of JFreeChart. Panning should be supported from version 1.0.13 onwards.

Locked