XYpic for arrows in TeX
- To: mathgroup at yoda.physics.unc.edu (Mathematica Discussion Group)
- Subject: XYpic for arrows in TeX
- From: Ross_Moore at mac-mpce-services.mpce.mq.edu.au (Ross Moore)
- Date: Thu, 10 Sep 1992 18:15:36 +1000
There have several requests for methods to augment Mathematica graphics with
labels and arrows.
Some suggestions have been to use PostScript-generating applications like
Adobe Illustrator.
This is fine provided the labels are to be linear text, but not so good for
mathematical expressions.
If the ultimate aim is to use TeX, then there are some useful macros by
Kristoffer H Rose, Univ. of Copenhagen, Denmark ( kris at diku.dk ).
They come with their own fonts for drawing lines and arrowheads at 128
different directions, and quarter circles at a wide range of point-sizes.
The distribution available from ftp.diku.dk [129.142.96.1]
includes macros, manual, .pk fonts and Metafont sources.
None of Kris's manual examples deal with the graphics labelling problem
directly, but these macros are indeed well-suited to this problem.
I have just finished preparing Macintosh font suitcases for use with
TeXtures, in a range of sizes for both screen display and laser printing.
My examples and fonts are now available by anonymous ftp.
The remainder of this posting is the README file ...
***************************************************
xyPic.README from /pub/maths/TeX/XYpic @ ftp.mpce.mq.edu.au
by Ross Moore, ross at macadam.mpce.mq.edu.au
Dept of Mathematics
Macquarie University
Sydney, Australia, 2109
Files to be found in this directory relate to the use of XYpic
macros for creating labels & arrows to parts of graphics within
TeX documents. Also there are font suitcases for use with the
TeXtures application on a Macintosh computer.
*************************************************************
The XYpic macros were written by ...
Kristoffer H Rose kris at diku.dk
Univ. of Copenhagen
Denmark
... they can be obtained by ftp from ftp.diku.dk [129.142.96.1].
This ftp site contains two archives containing...
1. macros + examples + .pk fonts in a range of useful sizes
2. macros + examples + Metafont descriptions
the manual is also available as a PostScript file.
The file xypicready.tar.Z is a copy of archive 1 above.
*************************************************************
There are many maths applications for these XYpic macros:
e.g.
Commutative Diagrams, Graph-Theory, finite State-machines
Another use, which does not appear in the manual, is in labelling
graphics with arrows to indicate special features. There have been
many requests in Internet news-groups for such capabilities,
in particular for Mathematica-generated graphics.
One of the files here gives an example of how XYpic can be used to
perform this task most admirably.
Also there are suitcases of font files for use with the superb
TeX implementation TeXtures, from Blue Sky Research.
*************************************************************
Where appropriate files have been archived from a Macintosh using
1. Stuffit v1.5.1 ** -> **.sit
2. BinHex'd v 4.0 ** -> **.hqx
3. compressed under Unix ** -> **.Z
( hence the file names of the form: **.sit.hqx.Z )
*************************************************************
Description of files:
XYfonts.sit.hqx
is a Stuffit archive containing font suitcases for Macintosh/TeXtures
1. XYfonts uncompressed size = 824k
most of the fonts, design size = 10pt
screen sizes : 10pt 12pt 20pt 24pt
laserwriter : \magstep0 ( = 42pt), \magsteps .5,1,2,3,4,5
2. xymisc uncompressed size = 981k
font for large circle pieces, design size = 10pt
screen sizes : 10pt 12pt 20pt 24pt
laserwriter : \magstep0 ( = 42pt), \magstep1 ( = 50pt)
(larger sizes get to be enormous !!)
3. xymetrics uncompressed size = 5k
font metrics for all XYpic fonts, for use with TeXtures.
WARNING (technical, re fonts, Macintosh only ):
The fonts NFNT resource IDs in these archives have been regularized so
that different point-sizes of the same font have related IDs:
ID = 128 * family# + pointsize
except where this clashes with other TeX fonts similarly regularized,
in which case a nearby ID has been chosen.
Check for ID clashes on your system.
Use ResEdit or some other utility to alter the NFNT and FOND resources.
xyPicTest.sit.hqx
is a Stuffit archive containing examples relating to XYpic.
1. xyPicTest.tex (uncompressed size = 34k, incl PICT graphic)
TeXtures document containing a PICT graphic with parts labelled
using arrows pointing in various directions.
Only the command \picture dependent on TeXtures, the remainder of
the code is Plain TeX + XYpic .
Only the \special{picture ...} command is specific to TeXtures,
so this should TeX on other systems, but without the graphic.
(The graphic was generated in Mathematica.)
2. xyPicTest.ps (uncompressed size = 87k)
PostScript version of the above tex-file: xyPicTest.tex
generated from TeXtures. This contains the AppleDict, so should
print correctly if downloaded to any PostScript printer.
3. testxyfonts.tex (uncompressed size = 22k, incl DVI2 resources)
TeXtures document which generates tables to view the complete suite
of xyfonts at a particular \magstep.
The code is Plain TeX + XYpic .
xypicready.tar
is a unix tar archive containing the XYpic macros + examples + .pk fonts.
This file was created by Kristoffer H Rose;
it has been copied from the ftp site at ftp.diku.dk [129.142.96.1] .
*****************************************************
I would be most interested in any novel or elegant uses you find for these
macros and fonts.
Use and enjoy.
Ross Moore.