Hi Thomas and Cameron,

A long time ago (several months/years) I started discussing this issue (can't remember where it is in the archives). I would like to restart this discussion again and hope that you can find a solution for my problem.

Here is the problem:
there are two or more <svg/> elements nested into a parent <svg/> element, just like the following structure:

<svg viewBox="0 0 1000 700">
<svg id="map1" x="10" y="10" width="300" height="300" viewBox="600000 200000 100000 100000">
      <!-- some map content that is bigger than the specified viewBox -->
   </svg>
<svg id="map2" x="320" y="10" width="300" height="300" viewBox="600000 200000 100000 100000">
      <!-- some map content that is bigger than the specified viewBox -->
   </svg>
   <!-- and maybe a third, fourth or fifth svg element -->
</svg>

Now with Batik's current behavior, if the content of "map2", which is hierarchically higher in the tree, is a lot bigger than the specified viewBox (which is typical in many mapping or other applications) then "map1" won't receive any events, because the invisible content of "map2", although not visible, still receives the events because it overlaps content of "map1".

Here are two examples illustrating the problem:

http://www.carto.net/papers/svg/gui/scrollbar/index.svg
The two images are bigger than the viewBox of the two nested <svg/> elements. If the lower images (which is hierarchically higher than the upper image) is panned such that parts of the image overlap with the upper image, the upper image doesn't receive any events.

http://www.carto.net/papers/svg/navTools2/index.svg (still a buggy prototype) If you display 2 to 4 maps (change with the selectionLists) there is a big mess if the contents of the adjacent <svg/> elements overlap.

I know that the behavior isn't specified in the SVG 1.1 spec, but I raised an issue with the SVG WG and they will address this in the SVG 1.2 full or an SVG 1.1 errata. I examined this behavior in other SVG 1.1 full viewers. Here is the result:

* ASV isn't sensitive outside the specified viewBox (it hadn't been for years) * Opera9 initially behaved like Batik, but changed the behaviour after I contacted them, prior to the official version 9 release * Firefox: FF1.5 and FF2 beta behave like Batik today, however there is a patch now for the trunk version (FF3) and I hope that this patch will eventually make it into FF2 final to align the behavior with ASV and Opera9

What is your opinion on this? Are you able to provide a fix for this behavior as well, even if it isn't (yet) specified in the current spec?

Thank you for discussing this problem and maybe considering patching Batik's behavior.

Andreas

--
----------------------------------------------
Andreas Neumann
Institute of Cartography
ETH Zurich
Wolfgang-Paulistrasse 15
CH-8093  Zurich, Switzerland

Phone: ++41-44-633 3031, Fax: ++41-44-633 1153
e-mail: [EMAIL PROTECTED]
www: http://www.carto.net/neumann/
SVG.Open: http://www.svgopen.org/
Carto.net: http://www.carto.net/


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to