Mike,
The Geochrono unit (million of years) is implemented in this file
http://simile.mit.edu/timeline/api/ext/geochrono/scripts/units.js
So, to reverse the direction, make a copy of the dinosaur example, and
then right before the function onLoad, add something like this
Timeline.GeochronoUnit.compare = function(v1, v2) {
var n1, n2;
if (typeof v1 == "object") {
n1 = v1._n;
} else {
n1 = Number(v1);
}
if (typeof v2 == "object") {
n2 = v2._n;
} else {
n2 = Number(v2);
}
return n1 - n2;
};
Timeline.GeochronoUnit.change = function(v, n) {
return new Timeline.GeochronoUnit._MA(v._n + n);
};
Note that this is a hack, though, and I wouldn't recommend abusing the
Geochrono unit for that. I'd recommend getting someone with Javascript
expertise to write an extension to Timeline (much like this Geochrono
extension) that handles "page unit".
Perhaps something more closely related to what you want to do is this
planning example:
http://people.csail.mit.edu/dfhuynh/misc/planning.html
which shows Days, Weeks, and Quarters.
David
Mike Elkink wrote:
> Hello All,
>
> I'm curious as to whether or not someone can tell me how to go about
> reversing the direction of the date display in the dinosaur timeline.
>
> I'm attempting to use the timeline in a non-traditional way. I've
> been tasked with creating a visualization of changes in handwriting in
> a manuscript. The manuscript would be passed around from person to
> person, each making notes and adding annotations to the text. This
> means that my basic unit of measurement is the page rather than a
> specific time.
>
> The dinosaur example works incredibly well for me because it has
> placed it's units in millions of years ago. This relates well to the
> concept of a page with one million years equalling one page. I can
> also use the decimal notation to indicate placement within a page (ie
> there is an annotation 3/4 of the way down page 34).
>
> My problem is that the geochrono units count down rather than up and
> I'm not familiar enough with the code base to know what I have to do
> to modify the direction. I would really appreciate a bit of guidance
> as I've spent a couple hours wading through the js to no avail.
> Alternatively, if you could point me to an example that more closely
> matches what I'm attempting to do then I would be very much indebted.
>
> Thanks for your time.
>
> Mike
> _______________________________________________
> General mailing list
> [email protected]
> http://simile.mit.edu/mailman/listinfo/general
>
_______________________________________________
General mailing list
[email protected]
http://simile.mit.edu/mailman/listinfo/general