Re: panning a plot with datetick



The "zoomfixticks" function relies on an older API to the ZOOM function that
predates R14 (when the PAN tool was introduced). Pan uses a different API,
so the approach zoomfixticks uses will not apply. Currently, there is no way
to accomplish the same task for the PAN function. I have logged this as an
enhancement for a future version of MATLAB.

---
-Dan Sternberg
The MathWorks, Inc.

"helper" <spam@xxxxxxxxxx> wrote in message
news:ef2edc2.0@xxxxxxxxxxxxxxxxxxx
William L. Slater wrote:


Hello all:

I've been trying to figure this out for the past week with no
avail.
I'm working on a GUI that controls several axes in another figure.
These axes have time for the x-axis, and I can successfully use the
datetick function to make the labels show as a timestamp. The GUI
also lets the user zoom in close on any time window. Again, the
datetick function works perfectly here.

Where I have a problem is when I turn on the ability to pan along
the
x-axis. Panning to either the left or right, I do not have any new
tick marks (nor timestamps) to reflect the new limits made by
panning.

Is there some way I can place a callback to execute after panning
to
use datetick again and refresh the labels of the time axis?

There is, but it's not straightforward. Check out this file on the
FEX:

<http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=2090&objectType=file>

Greg does what you need for only zooming, but if you can figure out
what he is doing for zooming, you can do the same for panning.

Give it a look and see what you can do. It involves a lot of
overloading.


.



Relevant Pages

  • Re: panning a plot with datetick
    ... The "zoomfixticks" function relies on an older API to the ZOOM ... predates R14 (when the PAN tool was introduced). ... enhancement for a future version of MATLAB. ...
    (comp.soft-sys.matlab)
  • Starting MSIE from Vision web page
    ... with the pan & zoom function in MSIE, ... but the pan & zoom page is only supported by MSIE. ... I'd like to avoid making a page of ...
    (microsoft.public.visio.troubleshoot)