On Monday 01 June 2009 04:29:02 pm Paul A. Rubin wrote:
> Stefano Franchi wrote:
> > Problem: I have a small illustration produced with Inkscape and saved as
> > SVG. When I insert it into LyX as SVG, it gets converted to a bitmapped
> > image both in the LyX preview (which I don't care about) AND in the pdf
> > output (which I DO care about).
> > The SVG image looks all right when loaded into an SVG-aware app (e.g.
> > FIrefox).
> >
> > What I did:
> >
> > 1. I followed the instructions on the wiki and added format and
> > converters for SVG and SVG-->EPS, SVG-->PDF, SVG-->PNG
>
> You checked the vector graphics option, right?  (Just to be sure.)
>
> > Result: bitmaps both on screen and in Pdf
> >
> > 2. As suggested  in an older  thread, I tried removing the SVG-->PNG
> > converter.
> >
> > Result: as above
> >
> >
> > My setup is: Lyx 1.6.2 on Linux (Kubuntu 9.04) and Inkscape 0.46. I use
> > pdflatex to compile to pdf.
>
> I ran into this with LyX 1.6.1 on XP (Inkscape 0.46).  The reason for
> the bitmaps is that Inkscape is failing silently during the conversion,
> and so LyX is falling back on the generic conversion utility, which does
> not grasp SVG.  I'm not sure I ever figured out why it happened on XP,
> but adding the Inkscape directory to the system command path (and
> removing it from the LyX path prefix) seemed to fix it.  (I also used
> the Linux converter syntax:  '--export-pdf=$$o' rather than just 'PDF'.)
>
> I just checked on my office machine (Ubuntu 9.04, LyX 1.6.2) and the
> Linux instructions from the wiki seem to work ok.  You might want to run
> 'which inkscape' in a terminal just to be sure that LyX (or Python, as
> the case may be) can find Inkscape.  As Guenter suggested, you should
> also try 'inkscape --export-pdf=myfile.pdf myfile.svg' in a terminal to
> make sure the conversion works outside LyX.

That may be it. Inkscape seems to fail the SVG --> PDF conversion in batch 
mode. It seems to be a known bug of version 0.46 (the latest version, I 
believe). At least the Inkscape bugtracker reports a known bug in version 0.46 
for the opposite conversion path in batch mode (PDF-->SVG). I will try to 
upgrade to the latest SVN version to see if the problem is solved. 

It seems, however, that, even when working, the Inkscape Cairo-based routines 
to convert to Pdf leave a lot to be desired, From the Inkscape dev list in 
summer 2008:

It doesn't support Patterns, Clipping, and Masks and 
evince won't display the gradients with transparency correctly but 
Acroread will. 
 

Is anyone encountering these kind of problems?

S.



______________________________________________________________
Stefano Franchi
Department of Philosophy          Ph:  (979) 862-2211
Texas A&M University              Fax: (979) 845-0458
305B Bolton Hall                  [email protected]
College Station, TX 77843-4237

Reply via email to