Reputation: 11087
Is there any JS library designed for working with canvas elements?
I don't really care about IE compatibility. I need to create objects(complex drawings with text) , draw lines between them, linear, bezier with different strokes, and attach event handlers to them(i need mouseOver and click).
Anyone has any experience with a library that has built-in support for this?
EDIT: http://raphaeljs.com/ seems to have these features
Upvotes: 3
Views: 317
Reputation: 4928
CAKE fulfills some of your requirements:
http://glimr.rubyforge.org/cake/canvas.html#KeyboardTest
It's been abandoned by its author, though, so it's doubtful that the areas its lacking in will be improved any time soon.
Upvotes: 2
Reputation: 11464
Canvas doesnt support javascript, but SVG does. You could use jQuery to attach events etc to elements, just like other Dom elements.
Upvotes: 2
Reputation: 76
Well the Mozilla's API is quite good for working with canvas https://developer.mozilla.org/en/drawing_graphics_with_canvas
What's lacking? What would you like to see in a canvas library? - it might be a good project to be done on sourceforge or perhaps YUI or jquery can include it if you write to them about it.
Upvotes: 1