NAME

fig2MF — convert Fig code to mfpic METAFONT macro code SYNOPSIS

fig2MF [options] [files] DESCRIPTION

With fig2MF, any tool that generates version 2.1 Fig graphics code (such as the X Windows drawing tool, xfig), can be used as a METAFONT font creation tool. fig2MF reads from the named files or from the standard input file if no files are specified. The META-FONT code is written to the standard output file. The output is commented and formatted to aid manual editing. fig2MF supports these Fig objects:

• ellipses (and circles)

• polylines

• splines

• arcs

Compound objects are recognized but not are treated specially. OPTIONS

All of fig2MF’s options take the form of -opt=value and can occur anywhere on the command line. The options effect the filenames that they precede on the command line, and may be repeated with different values for different files. For example,

    fig2MF -xpos=4 foo.fig -xpos=5 bar.fig >foobar.fig

sets the xpos value to 4 for the file foo.fig, and sets the xpos value to 5 for the file bar.fig. All of the other options take their default values. The METAFONT code is written to the file foobar.mf.

Option  Default Value  Description
-mag  1000  Font magstep
-code  32  Initial METAFONT font code value
-pen  0.5  Size of the METAFONT pen (points)
-xscale  0.125  x coordinate scaling factor
-yscale  0.125  y coordinate scaling factor
-xneg  0.0  Minimum x coordinate value of the figure (inches)
-xpos  8.0  Maximum x coordinate value of the figure (inches)
-yneg  0.0  Minimum y coordinate value of the figure (inches)
-ypos  8.0  Maximum y coordinate value of the figure (inches)
-top  8.0  Top of the whole coordinate system (inches)

The x, y coordinate and scaling factors are arbitrary and should be adjusted to fit both the Fig generating tool and the desired size of the font.

FILES graphbase.mf — mfpic METAFONT macros.

DIAGNOSTICS fig2MF complains about inaccessiable files, malformed objects and input that is not in Fig version 2.1 format.

BUGS

• Text objects and EPS boxes are ignored.

• There is no attempt to determine the figure’s bounding box.

• Arrowed and non-solid lines styles are not supported.

SEE ALSO Thomas Leathrum, Pictures in TEX with METAFONT bm2font(1), xfig(1), fig(4)

AUTHOR Anthony Starks