Drawing with TeX

There are many packages to do pictures in (La)TeX itself (rather than importing graphics created externally), ranging from simple use of LaTeX picture environment, through enhancements like epic, to sophisticated (but slow) drawing with PiCTeX. Depending on your type of drawing, and setup, here are a few systems you may consider:

  1. pict2e; this was advertised in the LaTeX manual, but didn't appear for nearly ten years after publication of the book! It removes all the petty niggles that surround the use of the picture environment. It therefore suffers only from the rather eccentric drawing language of the environment, and is a far more useful tool than the environment itself has ever been.
  2. pstricks; this gives you access to all the power of PostScript from TeX itself, by sophisticated use of \specials. You need a decent DVI to PostScript driver (like dvips), but the results are worth it. The well-documented package gives you not only low-level drawing commands (and full colour) like lines, circles, shapes at arbitrary coordinates, but also high-level macros for framing text, drawing trees and matrices, 3D effects, and more. PDFTeX users may use pdftricks, which (like epstopdf - see PDFLaTeX graphics) generates PDF files on the fly from pstricks commands.
  3. MetaPost; you liked Metafont, but never got to grips with font files? Try MetaPost - all the power of Metafont, but it generates PostScript figures; MetaPost is nowadays part of most serious (La)TeX distributions. Knuth uses it for all his work...
  4. Mfpic; you liked Metafont, but can't understand the language? The package makes up Metafont or MetaPost code for you within using familiar-looking TeX macros. Not quite the full power of Metafont, but a friendlier interface.
  5. You liked PiCTeX but don't have enough memory or time? Look at Eitan Gurari's dratex, which is as powerful as most other TeX drawing packages, but is an entirely new implementation, which is not as hard on memory, is much more readable (and is fully documented).
dratex.sty
graphics/dratex (zip, browse)
mfpic
graphics/mfpic (zip, browse)
pdftricks.sty
macros/latex/contrib/pdftricks (zip, browse)
pict2e.sty
macros/latex/contrib/pict2e (zip, browse)
pstricks
graphics/pstricks (zip, browse)

This question on the Web: http://www.tex.ac.uk/cgi-bin/texfaq2html?label=drawing