"menu" tag supported by adobe for context menu. "menu" tag is not supported when running example ExampleSVG2PDF
Created attachment 14644 [details] SVG test File
Dynamic contextmenu Creation manipulated by JAVASCRIPT to creat diffrent menu , supported by adobe SVGViewer.
Your example file gives me error messages in Adobe SVG Viewer and Batik Squiggle. You seem to use an old SVG dialect (SVG 1.0 Candidate Recommendation) which is totally out of date. And then I can't find any reference to the "menu" elements in any of the SVG specifications. So it is not clear to me what you're trying to do here. You might want to be a bit more verbose about that. Where are these menus defined? Does Batik itself support them? If Batik doesn't, FOP won't, either. I also don't see how this can be implemented in PDF in the first place.
(In reply to comment #3) > Your example file gives me error messages in Adobe SVG Viewer and Batik > Squiggle. You seem to use an old SVG dialect (SVG 1.0 Candidate > Recommendation) which is totally out of date. And then I can't find any > reference to the "menu" elements in any of the SVG specifications. So it is > not clear to me what you're trying to do here. You might want to be a bit more > verbose about that. Where are these menus defined? Does Batik itself support > them? If Batik doesn't, FOP won't, either. I also don't see how this can be > implemented in PDF in the first place. The code can't work by itself , it is looking for JavaScript functions that manipulate the SVG output (Context Menu of Adobe is working not Only in Adobe I tried it also in corel SVG viewer and it's worked just fine. I can attaché SVG with no calls to any JS function. and regarding the your question , "How this(Menu)can be implemented in PDF in the first place" My answer is that I don't need implementation of it , I want only that Batik ignore it - it's not an error to use it.
(In reply to comment #4) > "How this(Menu)can be implemented in PDF in the first place" My > answer is that I don't need implementation of it , I want only that Batik > ignore it - it's not an error to use it. It is an error to use it. You can not add arbitrary elements to the SVG namespace. If the menu element were in another namespace (say Adobe something) Batik would ignore it and processes the elements in the SVG namespace but you can not place arbitrary elements in the SVG namespace, it is a violation of the SVG specification.
(In reply to comment #5) > (In reply to comment #4) > > "How this(Menu)can be implemented in PDF in the first place" My > > answer is that I don't need implementation of it , I want only that Batik > > ignore it - it's not an error to use it. > It is an error to use it. You can not add arbitrary elements to > the SVG namespace. If the menu element were in another namespace > (say Adobe something) Batik would ignore it and processes the elements > in the SVG namespace but you can not place arbitrary elements in the SVG > namespace, it is a violation of the SVG specification. The use of "menu" in Adobe can be explained in the following web site(there are examples to test) : http://www.xml.com/pub/a/2002/07/03/adobesvg.html
Reading this makes it clear that it is your use of the feature that is the problem. You (or someone) has choosen to store 'proxies' of the menu content in the SVG file in the SVG namespace. At some point these elements are copied/imported into the contextMenu's document. There is no problem with the Adobe context menu document having these elements the problem is that this document has added these elements to an SVG document in the SVG namespace. I suspect that all you really need to do is add a default namespace decl to the menu item to move them out of the the SVG namespace into a suitable 'extension' namespace. The method that constructs the menu in the contextMenu document might need some adjustment but probably not.
Bugzilla cleanup: Not a FOP bug, not even a bug...?
batch transition to closed remaining pre-FOP1.0 resolved bugs