Logo OS Reviews

Reviewing Freedom.



Fast Figures

Hendrik Weimer


Print version

Slashdot me! Digg me! Stumble me! del.icio.us

There are often situations in which it is necessary to create a figure for visualizing a concept, providing an existing figure with some additional annotations or just making a fancy-looking technical drawing. Xfig is a program to perform these tasks which require something in between a CAD tool and a vector graphics program.

When you launch Xfig for the first time, everything will look quite normal first. The user interface looks a bit antique, but there are menus, buttons for drawing and manipulating objects, a toolbar and a status bar. However, once you try to draw, say, a line, you will suddenly notice that you can't finish a line with the left mouse button but with the middle button instead. Xfig is full of such little oddities, with the Athena-like scrolling being the worst of all. In this respect Xfig looks like a weird UNIX program from the 80s that has risen from the dead. Fortunately, there is always a widget that describes precisely what the different mouse buttons would do at the moment.

Once you have mastered the peculiarities of its user interface, Xfig will unveil its friendly side. You can easily draw various simple geometric figures such as rectangles, circles, polygons and various splines. The position of each point defining the object can be moved, either by using the mouse or entering the precise coordinates into a dialog. The latter is extremely powerful when creating objects with specific geometric proportions.

Editing a schematic

Editing a schematic
(click to enlarge)

As with other drawing programs, Xfig allows the user to split more complex objects into smaller components up to single lines or put them back together. Working in grid mode makes it sometimes difficult to make Xfig actually select the object if it's not properly aligned on the grid. The behavior of overlapping objects can be controlled by putting them onto different layers and various simple transformations such as rotating and flipping objects are provided as well. This allows to quickly create even complex drawings.

Other images can be embedded, however if you want to edit the image with Xfig, it has to be converted first to Xfig's own data format. The pstoedit tool (not included in Xfig) can do that, but as the name suggests only accepts Postscript input. Some programs (e.g. gnuplot) have an Xfig exporter, which avoids additional conversion woes.

On the other hand, Xfig can export to a plethora of graphics formats. Despite the usual suspects such as PNG, JPEG, Postscript and PDF, there are even several different LaTeX exporters that should should satisfy your needs. Using Xfig to create figures and annotate plots for subsequent inclusion into LaTeX documents is a common practice in scientific publications.

So if you survive the first contact with its user interface, Xfig can be used to create simple and complex figures without too much hassle.

Distributions: [?]■ Debian stable■ Debian unstable
■ Fedora■ Mandriva
■ Suse■ Ubuntu


  • Quick generation of figures
  • Editable data points
  • Awkward user interface
  • Only one undo level

Copyright 2006–2008 OS Reviews. This document is available under the terms of the GNU Free Documentation License. See the licensing terms for further details.