Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Inkscape screws up EPS files

I have been trying to use Inkscape to prepare artwork graphics for my scientific papers. I use LaTeX, and I need my figures to be prepared as high-quality Encapsulated PostScript (EPS) images. The work order is as follows. First, I plot parts of my figure using matplotlib and save them in EPS format. Second, I launch Inkscape and import the EPS files. Using Inkscape I compose a figure, leaving needed objects, killing unneeded, and adding some markups. So I used to do when I worked with CorelDraw in Windows, but now I work in Linux.

Unfortunately, Inkscape damages EPS files: it changes the colors and does not save all the objects. Over last years I tried to search for a solution, but I cannot find that people complained. The complaints (found on the Web) are related to something like "incorrect font rendering" when exporting from svg to eps or back. (For me this is not a problem - the text always can be represented as curves).

I currently work in Mandriva Linux 2010 and use Inkscape version 0.47 r22583 (Jan 14 2010). Somewhere I read that such problems could be caused by some outdated versions of cairo - mine is 1.9.14. I spend a lot of effort to build newer cairo (1.12.14), but I am still far from the purpose. I got confused in 32 and 64-bit libraries coexisting in my system...

I would be very grateful to anyone who has similar problems and, may be, advanced further towards the solution. Let me illustrate the problem.

Sorry, I do not have enough reputation points to neither post images nor insert more than 2 links, so, please take a look at the copy of this post with the images in my livejournal page:

http://benkev.livejournal.com/1093.html

The figure captions are below.

(1) Here are the three eps images I would like to combine in one figure:

(2) Here is what I get after importing the images in Inkscape and saving in SVG format. Note color and resolution distortion. Also, I draw three red circles around the feature of interest.

(3) Here is what I get when I export this figure to EPS file. One can notice that one of the three red circles gone: only two circles left!

Thank you!

like image 411
Benkevitch Avatar asked Jun 21 '13 23:06

Benkevitch


2 Answers

This appears to be a bug in inkscape. The following steps might help:

  1. Open the svg file in inkscape.
  2. Select all (Ctrl+A)
  3. Un-group (Ctrl+Shift+G). you may need to repeat this step several times.
  4. Save the result as eps format.
like image 105
NKN Avatar answered Sep 22 '22 06:09

NKN


For what it's worth after more than one year: I've been experiencing the same problems with Inkscape V0.48: the EPS was missing items when opened in other software (e.g. Latex).

I didn't completely solve the problem, but I found that it helped to remove groups. Simply select all components and keep ungrouping until there are no groups left. Save as EPS and the result should be better.

If there are still items missing, try to use 'raise selection up to top' on the missing items and save again.

like image 22
Marijn Avatar answered Sep 20 '22 06:09

Marijn