sangltdn / flot

Automatically exported from code.google.com/p/flot
MIT License
0 stars 0 forks source link

jquery.flot.navigate.js pan mode #305

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I needed to be able to pan a graph only at the X-axis.

So I created the attached patch, which adds a mode parameter, similar to 
crosshair and selection.
When setting mode to "x", it's only possible to "drag" the graph along the 
X-axis and vice versa for 
"y".

Default mode is "xy", so it behaves as it did previously.

Original issue reported on code.google.com by par.mika...@gmail.com on 15 Feb 2010 at 5:27

Attachments:

GoogleCodeExporter commented 9 years ago
Here's an updated patch which also works well with the realtime panning 
animation of the latest flot.

Original comment by honglilai@gmail.com on 2 Jul 2010 at 12:40

Attachments:

GoogleCodeExporter commented 9 years ago

Original comment by honglilai@gmail.com on 2 Jul 2010 at 12:41

Attachments:

GoogleCodeExporter commented 9 years ago
I've applied this patch along some extra documentation to my temporary fork: 
http://github.com/FooBarWidget/flot/commit/a72f1e5b222126bfc3981d3d7ca6903e6d3b1
76d

Original comment by honglilai@gmail.com on 14 Aug 2010 at 3:32

GoogleCodeExporter commented 9 years ago
Hi! I just merged a patch from somebody else with the same effect, although the 
syntax there is that you set panRange on the axis to false. I actually think 
your option syntax is much clearer and was going to pull out the other patch 
and apply yours, but I then realized it is a bit less generic in that you for 
instance can't have two x axes where one of them can be panned while the other 
stays fixed. I actually know a use case for that.

So I'll just close this. Thanks anyway!

Original comment by olau%iol...@gtempaccount.com on 10 Mar 2011 at 8:06

GoogleCodeExporter commented 9 years ago

Original comment by dnsch...@gmail.com on 4 Jun 2012 at 2:52