Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use custom time as zoom center in Timeline? #30

Closed
joefutrelle opened this issue Sep 17, 2012 · 2 comments
Closed

Use custom time as zoom center in Timeline? #30

joefutrelle opened this issue Sep 17, 2012 · 2 comments
Labels

Comments

@joefutrelle
Copy link

My app uses very large numbers of events (well over what is recommended) and is focused on delivering lots of information about the event located at the custom time:

http://ifcb-data.whoi.edu/mvco

However zoomability doesn't seem to be configurable to allow me to use the custom time as the zoom center. Rather I see the following behavior:

  1. When zooming with the mouse scroll wheel, the zoom center is the current mouse position
  2. When zooming with the zoom button (e.g., on a tablet) the zoom center is the center of the currently-displayed range

Is there an option to use the custom time as the zoom center or is that a missing feature?

@josdejong
Copy link
Contributor

Nice application.

Your description of the zoom behavior is correct (point 1 and 2). The zoom behavior is similar to that of Google Maps, and is indeed not configurable. I strongly doubt whether it is a good idea to change this zoom behavior and mess with users navigation expectations/habits.

Maybe you should look in a different direction to find a good way to navigate your data around the custom time? What about having a small menu on top of the timeline, with shortcuts to move the visible range to the mostly used ranges? Something like:

Show: Current day, Current week, Current month, Current Year

in which the links will move the Timeline such that the custom time is in the center, and zoomed to the appropriate level.

A completely different solution would be to put an event listener on the rangechange and rangechanged events, and when the Timeline is moved/zoomed by the user, change the custom time such that it stays in the center of the currently visible area. Another event listener can listen for the timechanged event (triggered when the user has dragged the Custom Time bar), and adjust the visible area again such that the custom time stays in the center again. Nicest is of course to do the latter in an animated way (see example21).

@joefutrelle
Copy link
Author

Very useful suggestions, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants