You must use an actual javascript Date object, not a date string.
Use Timeline.DateTime.parseGregorianDateTime("Jan 12 2013") or new Date("Jan 12
2013")
You can center the timeline upon creation by specifying todays date when you
create the bandInfos:
var bandInfos = [
Timeline.createBandInfo({
width:"33%",
intervalUnit : Timeline.DateTime.YEAR,
intervalPixels : 300,
date: new Date(), // tell JS to use *right now* as the center
date for the band
theme : my_theme
}),
// add'l bandInfos hereā¦
];
You can also center the timeline at any time dynamically by calling
.setCenterVisibleDate() on the band.
tl.getBand(0).setCenterVisibleDate(new Date())
This can be done at any time after the Timeline has been created. If you have
bands that are not sync'ed together, then you'll need to call
.setCenterVisibleDate separately for each band.
I don't know what createStoryJS is doing, so it's harder to say how to manage
your zoom levels.
Once your timeline has been created, look in the javascript console/debugger
and examine the _zoomSteps array for the band you are trying to zoom in on.
That will show you what zoom levels have been created for that band.
enter tl.getBand(0)._zoomSteps in the console and you should see an array of
objects.
--Mike
On Feb 6, 2013, at 7:07 AM, Dan wrote:
> I'm still really struggling with this. I'd be so greatful if anyone can
> offer any help.
>
> I've bypassed the issue of focussing the timeline at today's date and instead
> have set it to use the last event instead, which is passable for the client.
> I've also set the 'start_zoom_adjust' value to 6 which does zoom somewhat.
> However, on the timeline itself the zoom in (plus) button won't zoom any
> further, and actually I'd like the zoom to default to around 8 or 9 rather
> than 6, but when I set this it doesn't do anything.
>
>
> $(document).ready(function() {
> createStoryJS({
> type: 'timeline',
> width: '970',
> height: '600',
> start_at_slide: '35',
> start_zoom_adjust: '6',
> source:
> '/about/timeline-page/TimelineItems',
> embed_id: 'my-timeline',
> debug: true,
> css:
> '/timelinejs/compiled/css/timeline.css',
> js:
> '/timelinejs/compiled/js/timeline.js'
> });
> });
>
>
> Again, I'm really struggling to find documentation (Googling 'simile timeline
> start_zoom_adjust' yields just 3 results, none of which are useful) but I'm
> coming under a lot of pressure from the client now to get this finished. If
> anyone could please help me to understand how to zoom further than 6 by
> default, it would be much appreciated.
>
> Many thanks
>
>
--
You received this message because you are subscribed to the Google Groups
"SIMILE Widgets" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/simile-widgets?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.