graphics

Setting global XFig defaults for working with LyX/LaTeX

15 May, 2009 - 10:26

When making a document with Lyx (or LaTeX), I often create figures and diagrams in XFig. I know, Xfig's user interface sucks big time. (I tried the Java port JFig, but that one even feels worse to me.) However, the main reason I bite the bullet is that it enables a work flow where the text you add to the XFig figure is typeset by LaTeX when you compile the document. This way, the text in the figure is in the same font as the normal text in the document and, maybe more importantly, you can use all the fancy LaTeX commands, e.g. to put mathematical expressions, symbols and formulas in your figure.

To make this work, one of the required things is to enable the "special" flag on the text objects in XFig, and use a LaTeX font. These things are disabled by default and manually setting for every text object is a bit tedious. To changes these defaults, you can start xfig from the command like with the following options:

Read more...