Closed karolk closed 13 years ago
Obviously the rationale to make g.raphael work with callable g is to make porting existing code really easy. Apart from some things like animating scale, which has to be done with transform, adjusting old code only requires adding brackets after g.
I ported all g.raphael libraries. One important change in the API is you will have to call g, for example
var r = Raphael(elem, 100, 100) var graph = r.g().dotchart(/* params */)
Going forward I would evolve the charts APIs to have an alternative way of being called straight on raphael (like colopicker plugin).
I made all demos work, mostly by fixing this context and adjusting old way of scaling and rotating to the new transform API.