Inkscape Error!

Post questions on how to use or achieve an effect in Inkscape.
SuperInkscapeMan
Posts: 1
Joined: Fri Mar 25, 2016 11:01 pm

Inkscape Error!

Postby SuperInkscapeMan » Fri Mar 25, 2016 11:11 pm

Hey guys,
Yesterday I had nothing to do, so I decided to create a cartoon using inkscape.
I saved it and closed Inkscape. Nothing wrong witch that.
My actual problem is that I can't open it. when I tried to open it, it said that the file wasn't a valid XML-file.
I treid dragging it into inkscape and I looked in 'recent projets' but it didn't work.
I spend ike 4 or 5 hours on this project, so would be pleased if someone could help me out with this!
greets,
SuperInkscapeMan

Lazur
Posts: 4717
Joined: Tue Jun 14, 2016 10:38 am

Re: Inkscape Error!

Postby Lazur » Sat Mar 26, 2016 12:05 am

Hi.

Sounds it got corrupt. Usual scenario is when the save was not complete, meaning some parts of your file are missing preventing it from opening/rendering.
Svg files are xml documents, if you open it in a notepad it should end with a </svg> tag.
If it is missing, and other parts as well before it, you should add the tag.
Maybe even needs deleting "chopped in half" object and closing other groups with tags too.

Can you share the file?

Moini
Posts: 3381
Joined: Mon Oct 05, 2015 10:44 am

Re: Inkscape Error!

Postby Moini » Sat Mar 26, 2016 1:55 am

Also activate autosave to not loose any more work, but to keep snapshots of your work. Never close Inkscape too early while it is still saving.

Edit -> Preferences -> Input/Output -> Autosave
Something doesn't work? - Keeping an eye on the status bar can save you a lot of time!

Inkscape FAQ - Learning Resources - Website with tutorials (German and English)

User avatar
brynn
Posts: 10309
Joined: Wed Sep 26, 2007 4:34 pm
Location: western USA
Contact:

Re: Inkscape Error!

Postby brynn » Sat Mar 26, 2016 10:04 am

I think a lot of people have workflow:

work, work, work, look over work, save, close

better would be:

work, work, work, save, look over work, close

or if it's already a large file that is challenging resources (Inkscape going slow):

work, save, work, save, work, save, look over work, close

Amadeus12
Posts: 66
Joined: Sat Sep 11, 2010 4:20 pm

Re: Inkscape Error!

Postby Amadeus12 » Fri Apr 01, 2016 5:50 am

I use a tool like prettyprinter XML in the editor I use (Geany). It gives me the line number in which the mistake is found.
Furthermore, you can use the W3C-validator. If the file is corrupt, it will give you the place where it has found mistakes.
Another thing. Inkscape can be quite forgiving in depicting images that are technically not correct. But the start of the file must be entirely correct. It must be like this:

Code: Select all

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" >
<svg
   xmlns:dc="http://purl.org/dc/elements/1.1/"
   xmlns:cc="http://creativecommons.org/ns#"
   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"
   version="1.1"
   width="1183.5551"
   height="1015.838"
   viewBox="0 0 1183.555 1015.838"
   id="svg1.1"
   xml:space="preserve">

If the error is indeed to be found in the start of the file, replace it with above mentioned code. You can then change the width and the height of the image after you have opened the image in Inkscape.
Btw, you can always give the output of the errormessage in this forum.


Return to “Help with using Inkscape”