Hello!
I'm fairly new to Inkscape and SVG and would like any sort of help or push in the right direction.
I have several SVG shapes that are saved individually which I then imported to a new document to create a diagram. Is there a way that if I make a change to one original shape (i.e. square.svg, like changing it to a solid blue color) that when its saved, it also updates the color in the diagram document that I created?
I think this also ties with linking, but I haven't been able to successfully link an SVG file to another SVG. I can import it, but it doesn't create any relationship to the original svg shape file.
Any ideas?
Thanks in advance!
Applying Style Changes to SVG that updates other SVG Files?
Re: Applying Style Changes to SVG that updates other SVG Fil
Well, I'll be damned. Apparently there is. Not automatic, mind you, but after the initial "setup" you should be good to go.
Here are some links (I couldn't make them work in Inkscape though):
http://stackoverflow.com/questions/5451135/embed-svg-in-svg
This one was shown correctly in my browser (Opera): http://alchemise.net/Svg/Main.svg (look at the xml source of that svg so you can see how it works)
EDIT: I just realize you're new to Inkscape... So this might not help you at all.
But, well, good luck and welcome!
Here are some links (I couldn't make them work in Inkscape though):
http://stackoverflow.com/questions/5451135/embed-svg-in-svg
This one was shown correctly in my browser (Opera): http://alchemise.net/Svg/Main.svg (look at the xml source of that svg so you can see how it works)
EDIT: I just realize you're new to Inkscape... So this might not help you at all.
Re: Applying Style Changes to SVG that updates other SVG Fil
^ This is a very neat solution.
Still, if you find it dificult to apply - try with the Cloned duplicates. You`ll need to import desired/needed elements and Clone them. Later on, changes on the original element would apply on clones. Even later on, you could export these original elements as separate files (there are some scripts for batch expport on forum).
Still, if you find it dificult to apply - try with the Cloned duplicates. You`ll need to import desired/needed elements and Clone them. Later on, changes on the original element would apply on clones. Even later on, you could export these original elements as separate files (there are some scripts for batch expport on forum).
Re: Applying Style Changes to SVG that updates other SVG Fil
Thanks guys! I'll try both these methods and report back if I run into any issues 
Re: Applying Style Changes to SVG that updates other SVG Fil
Tried the recursion described on that site but it only "freezed" the programs -thumbnail image couldn't be generated in nautilus, and inkscape refused to open up. Would have been interesting.
Re: Applying Style Changes to SVG that updates other SVG Fil
Yeah, the only program where they worked for me was the Opera browser. I don't know if that's because the SVG specs have changed or simply because most SVG software doesn't implement that <image> tag.
Re: Applying Style Changes to SVG that updates other SVG Fil
So here are my results.
1. Using the <image> tag to reference external files and it worked to some extent. I was able to change the original svg file and it updated in the diagram, the only issue was that when I opened the diagram in Inkscape, all it showed were "image not found". I was however able to view it in several different browsers and it was fine, it was just not very useful for using Inkscape.
2. Cloning was an interesting approach however i was not able to get the two separate documents to connect, then again I'm not sure if i did this correctly.
Step 1: I saved my basic shape.
Step 2. Opened a new doc then imported that shape.
Step 3. I cloned the basic shape (SHIFT + D) in the new document, clicked save.
Then this is where I got lost as I tried to save this as a separate file, but there was no relationship between the original doc and this.
So, how do you get the cloned shape into a separate file? I know Maestral mentioned a script for Batch Export, but I couldn't find a link on here to how to do that.
And thanks everyone for all your replies, its really helping me through this troubleshooting.
1. Using the <image> tag to reference external files and it worked to some extent. I was able to change the original svg file and it updated in the diagram, the only issue was that when I opened the diagram in Inkscape, all it showed were "image not found". I was however able to view it in several different browsers and it was fine, it was just not very useful for using Inkscape.
2. Cloning was an interesting approach however i was not able to get the two separate documents to connect, then again I'm not sure if i did this correctly.
Step 1: I saved my basic shape.
Step 2. Opened a new doc then imported that shape.
Step 3. I cloned the basic shape (SHIFT + D) in the new document, clicked save.
Then this is where I got lost as I tried to save this as a separate file, but there was no relationship between the original doc and this.
So, how do you get the cloned shape into a separate file? I know Maestral mentioned a script for Batch Export, but I couldn't find a link on here to how to do that.
And thanks everyone for all your replies, its really helping me through this troubleshooting.
Re: Applying Style Changes to SVG that updates other SVG Fil
This is the script which I had in mind. To be franc, I haven`t tried it yet. On the other hand, is there any real need for separating basic shapes in the individual files?
Could you try to solve this with layers? This way, you`ll have basic shapes in one layer, placed somewhere outside of your "diagrams" which will be on separate layers? Another thing could be a "template file" just with the bacis shapes, which you`ll then edit and save as "diagram xy"?
Could you try to solve this with layers? This way, you`ll have basic shapes in one layer, placed somewhere outside of your "diagrams" which will be on separate layers? Another thing could be a "template file" just with the bacis shapes, which you`ll then edit and save as "diagram xy"?

