Negative values in absolute positions!!

Discuss SVG code, accessible via the XML Editor.
abmera
Posts: 2
Joined: Tue Sep 13, 2011 6:07 am

Negative values in absolute positions!!

Postby abmera » Tue Sep 13, 2011 6:18 am

Hello Guys,

I have built a converter to convert SVG path elements into.html

coiner
Posts: 19
Joined: Mon Mar 14, 2011 5:21 pm
Location: NY

Re: Negative values in absolute positions!!

Postby coiner » Tue Sep 13, 2011 12:04 pm

Not to crap all over your idea, but why would you convert a newer tech into old, basically deprecated one? This could easily be achieved using pure SVG.

abmera
Posts: 2
Joined: Tue Sep 13, 2011 6:07 am

Re: Negative values in absolute positions!!

Postby abmera » Tue Sep 13, 2011 4:23 pm

I need to utilize it on iPhone and android which I believe they do not fully support SVG. Beside I'm curious to know why there is negative values in absolute positioning. If you know a better way to do it in svg I'm very open to know it and use it.

coiner
Posts: 19
Joined: Mon Mar 14, 2011 5:21 pm
Location: NY

Re: Negative values in absolute positions!!

Postby coiner » Tue Sep 13, 2011 11:51 pm

I don't have an iPhone to test but I believe the only SVG it doesn't support are SMIL animations and it doesn't sound like you will need that for what you are doing. Most likely full support will happen in the coming months anyway, so you will be ahead of the game.

I have created a very quick example showing how you can have a map with links drawn out with a path in SVG. I have placed a link over the isle of Corsica on the map using a path. Note that the fill-opacity attribute is what makes the path transparent over the map.

Example: http://static.dorshnik.com/test/map-paths.svg

As for the negative values, I really don't know much about defining paths manually.

coiner
Posts: 19
Joined: Mon Mar 14, 2011 5:21 pm
Location: NY

Re: Negative values in absolute positions!!

Postby coiner » Wed Sep 14, 2011 9:15 am

I just borrowed an iPad and ran the acid test on the iOS Safari and it scored a 99 so SVG support is definitely available on the iPhone/Pad, I've yet to test an android but I would bet money it has full supp0rt.

User avatar
RobA
Posts: 335
Joined: Fri Aug 10, 2007 1:22 am

Re: Negative values in absolute positions!!

Postby RobA » Wed Sep 14, 2011 9:55 pm

To (try to) answer your actual question - Inkscape converts its user coordinates (0,0) bottom left into the svg standard (0,0) top right internaly. Is that where the negative could come from?

-Rob A>


Return to “SVG / XML Code”