Take a look at http://www.aitel.hist.no/~helgehaf/sw/figpdf.html The solution I have is a new external_template file that makes a new kind of external inset available - xfigpdf There's also a script that make this new inset work. You don't need compiling or any root privileges to use it.
Note that you will need transfig 3.2.3d, which is available in debian testing and probably in several other forms as well. You have to change your insets from xfig to xfigPDF type if you use this as-is. Consider _replacing_ the xfig inset instead of _adding_ xfigPDF if you have a lot of xfig you want processed this way. The obvious downside to this is that you'll no longer be able to generate postscript, you'll have to print the pdf files instead, using acroread or similiar. I have no solution that supports pdflatex and dvips at the same time. Either change the inset types, or switch between several external_inset files. Duncan Webb wrote: > > Hello all, > > First I would like to thank the developers of LyX, I think that is a great > tool. > > As we all know, since version 1.1 and 1.2 for LyX there has been some > changes in the way graphic files are handled, which is fine in most cases > but does cause additional work when exporting xfig diagrams in pdf files. > png files are horrid when presenting line art, eps and pdf are much better. > > The problem is that the default behaviour has changed in version 1.2, now > the extension of the figure must be specified whereas is version 1.1 it > could be left off and then LaTeX would use the best format possible. Now the > extension must be specified and LyX decides to use it own rules. > > The question is how can the default rule for xfig files be changed so that > when generating dvi files LyX uses eps graphics and when generating pdf > files it uses pdf files? > > Or alternatively is there a way when exporting as a LaTeX file to remove the > extension from the figure filenames, I read that this happens internally? > > At the moment I export the file as a LaTeX file and manually edit out the > extensions and use a make file to build the eps and pdf for the graphics and > then the pdf and dvi files. > > Thanks in advance > Duncan > > BTW We're using LyX 1.2.1