3. Installation


Basic Install

The plugin consists of two python files:

The first is for the embedding of LaTeX text, and the second for the optional saving of combined eps/epstex files. Although a direct .eps will generally give good results, the .epstex output can give better rendering quality and smaller file sizes.

These files must be copied to a location where they can be found by Skencil. This could be in the same place as the built-in plugins. On a typical system, this will be:

Alternatively, they could be put in the user directory, ~/.sketch/Plugins and the following added to ~/.sketch/userhooks.py:

from Sketch import config
import os


Once this is complete, there should exist a menu item, edit-->create-->LaTeX Text. This opens a dialog that can be used to create new text, or edit existing text. To edit existing text, open the dialog, and then select the text you would like to edit.


The plugin uses pstoedit (which in turn uses ghostscript) to convert the eps output from dvips into Skencil format, so this must be installed. Version 3.30 or later is required. It may be obtained from the pstoedit homepage, http://www.pstoedit.com/

Note (June 2005): There is a bug in pstoedit version 3.40 that affects the operation of SketchLaTeX. It causes incorrect rendering and segmentation faults when subpath simulation is turned on. The 2005-06-23 version of SketchLaTeX detects for this buggy version and disables subpath simulation. For some characters this may cause minor rendering problems. Until the next release of pstoedit, version 3.33 is recommended.

I would like to hear of any problems with the latest release of sketchlatex, in particular if there are any problems loading up files saved by earlier versions. Earlier versions of sketchlatex can also be used with pstoedit version 3.33. The source for that version is available from the debian mirrors.



Upgrading the plugin is simply a matter of replacing the two python files with the new ones.

epstex Usage

You may optionally use the epstex format for including the graphics into LaTeX files. Note that this is not necessary or generally recommended. Normally, you can just include the eps file directly into the LaTeX document as you would any other .eps file. However, if you save as file.epstex, the plugin will create two files: file.epstex, and file.eps, similar to the combined format of xfig. To use these in the LaTeX document, use the following in place of an \includegraphics command:

\input file.epstex

Next Page... Screen Capture