| Newsgroups |
gmane.text.xml.svg.devel |
| Message-ID |
<[email protected]> |
Domenico,
Thanks SO much for your response!
You asked:
why do you need to set the viewbox y to 890.5, and transform the image to that y value as well? That forces you to set the transforms for the other objects accordingly.
Frankly, that is because that is the way that Adobe Illustrator spit it out, and I didn't know any better so I didn't remove or change that before I went further.
I suppose that I could take (many) steps backwards and change that; that would also mean, I think, moving all of the vector objects, no? The application I am making use of not only lines up the vector objects with the raster image, but also places the tooltip objects that pop up in relation to them as well; well, actually I manually line up all of the tooltips with the vector dots.
You also recommend:
1) specify the width and height of the image (rather than 100%)
2) get rid of the viewbox attribute (it implicitly corresponds to the image dimensions)
3) get rid of that weird matrix. Set instead x="0.5", y="890.5".
4) get rid of the preserveAspectRatio attribute. If you do need to experiment with it read well the specification.
An earlier version started with your recommendations #1, #2, and #4. I only tried adding those later, in a trial-and-error test, based a little on other peoples guess-recommendations. I'll revert back, but the problemm still exists without them.
Regarding your recommendation #3: that was what was originally spit out by Illustrator, along with the viewBox attribute on the SVG element ("0.5 890.5 5954 3705"). So would you recommend removing the transform matrix from the image element and using x and y attributes instead, but leaving the viewBox value of the SVG element alone? Or do I need to step back many stages and change the SVG viewBox value to "0 0 5954 3705"? Why do you think Illustrator used those numbers?
Your advice GREATLY appreciated! I'm really stuck if I can't figure this out!
- Paul