DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://issues.apache.org/bugzilla/show_bug.cgi?id=35629>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ· INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=35629 Summary: Script events don't trigger on <defs> elements Product: Batik Version: 1.5 Platform: PC OS/Version: Windows XP Status: NEW Severity: normal Priority: P3 Component: Scripting AssignedTo: [email protected] ReportedBy: [EMAIL PROTECTED] Basically, when a script event is defined on an element in <defs> it doesn't seem to trigger. If it's added to a <use> element referencing the def it works. If included on both, only the <use> script event fires. Example is included below. Tested this on the Adobe SVG plugin 6.0 in both Explorer and Firefox and it triggers both events, the <use> event and the <def> event. ============================== <?xml version="1.0" encoding="UTF-8" standalone="no"?> <svg xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:cc="http://web.resource.org/cc/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" id="svg2" height="100" width="100"> <script language="javascript" id="script1292"> <![CDATA[ function showInfo(evt) { var msg = ""; if (evt.target != null) { msg += "Target: " + evt.target; } if (evt.currentTarget != null) { msg += "\n Clicked currentTarget: " + evt.currentTarget; } alert(msg); } function userPressedKey(evt) { var msg = ""; if (evt.currentTarget != null) { msg += "User pressed: " + evt.currentTarget.getAttribute("id"); } alert(msg); } ]]> </script> <defs> <rect id="FDK" y="5.0" x="5.0" height="30" width="30" style="fill:#eeff00" opacity="0.5" onclick="showInfo(evt)" /> </defs> <g id="layer1"> <use id="FDK-A" xlink:href="#FDK" onclick="userPressedKey(evt)" /> </g> </svg> -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
