mustang2247 / svgweb

Automatically exported from code.google.com/p/svgweb
Other
0 stars 0 forks source link

Implement getBBox() #457

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
There doesn't appear to be an implementation of getBBox() or anything else 
that will return positioning and size information for an SVG element. If I 
understand the source, this is on your TODO list. However it would be 
great to get it soon to enable the writing of really powerful mouse event 
handlers. For example I'm trying to port drag and drop code from a Firefox 
only javascript SVG implementation. (I love the idea of svgweb - thanks)

Original issue reported on code.google.com by DeclanMB...@gmail.com on 24 Feb 2010 at 7:51

GoogleCodeExporter commented 8 years ago
Luckily I do not think you need getBBox because what you do need for drag and 
drop
has already been implemented by Issue 225. I just attached an example file to 
Issue
225 that works with the latest version of SVG Web. The example implements drag 
and
drop on an element with a rotated coordinate system, which is pretty cool.

The reason you do not need getBBox or the location of the element is because the
system takes care of hit testing so what you really need are a way to transform 
mouse
event coordinates to the element's coordinate system. Exactly how to do that is 
what
Issue 225 is all about. Good luck!

I'll leave this issue open to represent the getBBox request.

Original comment by grick23@gmail.com on 10 Apr 2010 at 5:31

GoogleCodeExporter commented 8 years ago
Oh, this is a duplicate of Issue 417

Original comment by grick23@gmail.com on 10 Apr 2010 at 5:42