Newsgroups: comp.sources.unix From: envbvs@epb12.lbl.gov (Brian V. Smith) Subject: v27i057: transfig-2.1.8 - a set of tools for creating TeX documents with graphics, Part03/07 References: <1.749903574.10622@gw.home.vix.com> Sender: unix-sources-moderator@gw.home.vix.com Approved: vixie@gw.home.vix.com Submitted-By: envbvs@epb12.lbl.gov (Brian V. Smith) Posting-Number: Volume 27, Issue 57 Archive-Name: transfig-2.1.8/part03 #! /bin/sh # This is a shell archive. Remove anything before this line, then unpack # it by saving it into a file and typing "sh file". To overwrite existing # files, type "sh file -c". You can also feed this as standard input via # unshar, or by typing "sh 'Makefile' <<'END_OF_FILE' X# Makefile generated by imake - do not edit! X# $XConsortium: imake.c,v 1.65 91/07/25 17:50:17 rws Exp $ X# X# The cpp used on this machine replaces all newlines and multiple tabs and X# spaces in a macro expansion with a single space. Imake tries to compensate X# for this, but is not always successful. X# X X# ------------------------------------------------------------------------- X# Makefile generated from "Imake.tmpl" and X# $XConsortium: Imake.tmpl,v 1.139 91/09/16 08:52:48 rws Exp $ X# X# Platform-specific parameters may be set in the appropriate .cf X# configuration files. Site-specific parameters should be set in the file X# site.def. Full rebuilds are recommended if any parameters are changed. X# X# If your C preprocessor does not define any unique symbols, you will need X# to set BOOTSTRAPCFLAGS when rebuilding imake (usually when doing X# "make World" the first time). X# X X# ------------------------------------------------------------------------- X# site-specific configuration parameters that need to come before X# the platform-specific parameters - edit site.def to change X X# site: $XConsortium: site.def,v 1.2 91/07/30 20:26:44 rws Exp $ X X# ------------------------------------------------------------------------- X# platform-specific configuration parameters - edit sun.cf to change X X# platform: $XConsortium: sun.cf,v 1.72.1.1 92/03/18 13:13:37 rws Exp $ X X# operating system: SunOS 4.1.2 X X# $XConsortium: sunLib.rules,v 1.7 91/12/20 11:19:47 rws Exp $ X X# ------------------------------------------------------------------------- X# site-specific configuration parameters that go after X# the platform-specific parameters - edit site.def to change X X# site: $XConsortium: site.def,v 1.2 91/07/30 20:26:44 rws Exp $ X X SHELL = /bin/sh X X TOP = . X CURRENT_DIR = . X X AR = ar clq X BOOTSTRAPCFLAGS = X CC = cc X AS = as X X COMPRESS = compress X CPP = /lib/cpp $(STD_CPP_DEFINES) X PREPROCESSCMD = cc -E $(STD_CPP_DEFINES) X INSTALL = install X LD = ld X LINT = lint X LINTLIBFLAG = -C X LINTOPTS = -axz X LN = ln -s X MAKE = make X MV = mv X CP = cp X X RANLIB = ranlib X RANLIBINSTFLAGS = X X RM = rm -f X TROFF = psroff X MSMACROS = -ms X TBL = tbl X EQN = eqn X STD_INCLUDES = X STD_CPP_DEFINES = X STD_DEFINES = X EXTRA_LOAD_FLAGS = X EXTRA_LIBRARIES = X TAGS = ctags X X SHAREDCODEDEF = -DSHAREDCODE X SHLIBDEF = -DSUNSHLIB X X PROTO_DEFINES = X X INSTPGMFLAGS = X X INSTBINFLAGS = -m 0755 X INSTUIDFLAGS = -m 4755 X INSTLIBFLAGS = -m 0644 X INSTINCFLAGS = -m 0444 X INSTMANFLAGS = -m 0444 X INSTDATFLAGS = -m 0444 X INSTKMEMFLAGS = -g kmem -m 2755 X X CDEBUGFLAGS = -O X CCOPTIONS = X X ALLINCLUDES = $(INCLUDES) $(EXTRA_INCLUDES) $(TOP_INCLUDES) $(STD_INCLUDES) X ALLDEFINES = $(ALLINCLUDES) $(STD_DEFINES) $(EXTRA_DEFINES) $(PROTO_DEFINES) $(DEFINES) X CFLAGS = $(CDEBUGFLAGS) $(CCOPTIONS) $(ALLDEFINES) X LINTFLAGS = $(LINTOPTS) -DLINT $(ALLDEFINES) X X LDLIBS = $(SYS_LIBRARIES) $(EXTRA_LIBRARIES) X X LDOPTIONS = $(CDEBUGFLAGS) $(CCOPTIONS) $(LOCAL_LDFLAGS) X X LDCOMBINEFLAGS = -X -r X DEPENDFLAGS = X X MACROFILE = sun.cf X RM_CMD = $(RM) *.CKP *.ln *.BAK *.bak *.o core errs ,* *~ *.a .emacs_* tags TAGS make.log MakeOut X X IMAKE_DEFINES = X X IRULESRC = $(CONFIGDIR) X IMAKE_CMD = $(IMAKE) -DUseInstalled -I$(IRULESRC) $(IMAKE_DEFINES) X X ICONFIGFILES = $(IRULESRC)/Imake.tmpl $(IRULESRC)/Imake.rules \ X $(IRULESRC)/Project.tmpl $(IRULESRC)/site.def \ X $(IRULESRC)/$(MACROFILE) $(EXTRA_ICONFIGFILES) X X# ------------------------------------------------------------------------- X# X Window System Build Parameters X# $XConsortium: Project.tmpl,v 1.138 91/09/10 09:02:12 rws Exp $ X X# ------------------------------------------------------------------------- X# X Window System make variables; this need to be coordinated with rules X X PATHSEP = / X USRLIBDIR = /usr/lib X BINDIR = /usr/bin/X11 X INCROOT = /usr/include X BUILDINCROOT = $(TOP) X BUILDINCDIR = $(BUILDINCROOT)/X11 X BUILDINCTOP = .. X INCDIR = $(INCROOT)/X11 X ADMDIR = /usr/adm X LIBDIR = $(USRLIBDIR)/X11 X CONFIGDIR = $(LIBDIR)/config X LINTLIBDIR = $(USRLIBDIR)/lint X X FONTDIR = $(LIBDIR)/fonts X XINITDIR = $(LIBDIR)/xinit X XDMDIR = $(LIBDIR)/xdm X TWMDIR = $(LIBDIR)/twm X MANPATH = /usr/man X MANSOURCEPATH = $(MANPATH)/man X MANSUFFIX = l X LIBMANSUFFIX = 3 X MANDIR = $(MANSOURCEPATH)$(MANSUFFIX) X LIBMANDIR = $(MANSOURCEPATH)$(LIBMANSUFFIX) X NLSDIR = $(LIBDIR)/nls X PEXAPIDIR = $(LIBDIR)/PEX X XAPPLOADDIR = $(LIBDIR)/app-defaults X FONTCFLAGS = -t X X INSTAPPFLAGS = $(INSTDATFLAGS) X X IMAKE = imake X DEPEND = makedepend X RGB = rgb X X FONTC = bdftopcf X X MKFONTDIR = mkfontdir X MKDIRHIER = /bin/sh $(BINDIR)/mkdirhier X X CONFIGSRC = $(TOP)/config X DOCUTILSRC = $(TOP)/doc/util X CLIENTSRC = $(TOP)/clients X DEMOSRC = $(TOP)/demos X LIBSRC = $(TOP)/lib X FONTSRC = $(TOP)/fonts X INCLUDESRC = $(TOP)/X11 X SERVERSRC = $(TOP)/server X UTILSRC = $(TOP)/util X SCRIPTSRC = $(UTILSRC)/scripts X EXAMPLESRC = $(TOP)/examples X CONTRIBSRC = $(TOP)/../contrib X DOCSRC = $(TOP)/doc X RGBSRC = $(TOP)/rgb X DEPENDSRC = $(UTILSRC)/makedepend X IMAKESRC = $(CONFIGSRC) X XAUTHSRC = $(LIBSRC)/Xau X XLIBSRC = $(LIBSRC)/X X XMUSRC = $(LIBSRC)/Xmu X TOOLKITSRC = $(LIBSRC)/Xt X AWIDGETSRC = $(LIBSRC)/Xaw X OLDXLIBSRC = $(LIBSRC)/oldX X XDMCPLIBSRC = $(LIBSRC)/Xdmcp X BDFTOSNFSRC = $(FONTSRC)/bdftosnf X BDFTOSNFSRC = $(FONTSRC)/clients/bdftosnf X BDFTOPCFSRC = $(FONTSRC)/clients/bdftopcf X MKFONTDIRSRC = $(FONTSRC)/clients/mkfontdir X FSLIBSRC = $(FONTSRC)/lib/fs X FONTSERVERSRC = $(FONTSRC)/server X EXTENSIONSRC = $(TOP)/extensions X XILIBSRC = $(EXTENSIONSRC)/lib/xinput X PHIGSLIBSRC = $(EXTENSIONSRC)/lib/PEX X X# $XConsortium: sunLib.tmpl,v 1.14.1.1 92/03/17 14:58:46 rws Exp $ X XSHLIBLDFLAGS = -assert pure-text XPICFLAGS = -pic X X DEPEXTENSIONLIB = X EXTENSIONLIB = -lXext X X DEPXLIB = $(DEPEXTENSIONLIB) X XLIB = $(EXTENSIONLIB) -lX11 X X DEPXMULIB = $(USRLIBDIR)/libXmu.sa.$(SOXMUREV) X XMULIBONLY = -lXmu X XMULIB = -lXmu X X DEPOLDXLIB = X OLDXLIB = -loldX X X DEPXTOOLLIB = $(USRLIBDIR)/libXt.sa.$(SOXTREV) X XTOOLLIB = -lXt X X DEPXAWLIB = $(USRLIBDIR)/libXaw.sa.$(SOXAWREV) X XAWLIB = -lXaw X X DEPXILIB = X XILIB = -lXi X X SOXLIBREV = 4.10 X SOXTREV = 4.10 X SOXAWREV = 5.0 X SOOLDXREV = 4.10 X SOXMUREV = 4.10 X SOXEXTREV = 4.10 X SOXINPUTREV = 4.10 X X DEPXAUTHLIB = $(USRLIBDIR)/libXau.a X XAUTHLIB = -lXau X DEPXDMCPLIB = $(USRLIBDIR)/libXdmcp.a X XDMCPLIB = -lXdmcp X X DEPPHIGSLIB = $(USRLIBDIR)/libphigs.a X PHIGSLIB = -lphigs X X DEPXBSDLIB = $(USRLIBDIR)/libXbsd.a X XBSDLIB = -lXbsd X X LINTEXTENSIONLIB = $(LINTLIBDIR)/llib-lXext.ln X LINTXLIB = $(LINTLIBDIR)/llib-lX11.ln X LINTXMU = $(LINTLIBDIR)/llib-lXmu.ln X LINTXTOOL = $(LINTLIBDIR)/llib-lXt.ln X LINTXAW = $(LINTLIBDIR)/llib-lXaw.ln X LINTXI = $(LINTLIBDIR)/llib-lXi.ln X LINTPHIGS = $(LINTLIBDIR)/llib-lphigs.ln X X DEPLIBS = $(DEPXAWLIB) $(DEPXMULIB) $(DEPXTOOLLIB) $(DEPXLIB) X X DEPLIBS1 = $(DEPLIBS) X DEPLIBS2 = $(DEPLIBS) X DEPLIBS3 = $(DEPLIBS) X X# ------------------------------------------------------------------------- X# Imake rules for building libraries, programs, scripts, and data files X# rules: $XConsortium: Imake.rules,v 1.123 91/09/16 20:12:16 rws Exp $ X X# ------------------------------------------------------------------------- X# start of Imakefile X X# X# Top level Makefile for TransFig X# X# to make fig2dev: type "make" X# X XDEPLIBS = XSUBDIRS = transfig fig2dev X Xall:: X @case '${MFLAGS}' in *[ik]*) set +e;; esac; \ X for i in $(SUBDIRS) ;\ X do \ X (cd $$i ; echo "making" all "in $(CURRENT_DIR)/$$i..."; \ X $(MAKE) $(MFLAGS) 'CDEBUGFLAGS=$(CDEBUGFLAGS)' all); \ X done X Xdepend:: X @case '${MFLAGS}' in *[ik]*) set +e;; esac; \ X for i in $(SUBDIRS) ;\ X do \ X (cd $$i ; echo "depending" "in $(CURRENT_DIR)/$$i..."; \ X $(MAKE) $(MFLAGS) depend); \ X done X Xmanual: X Xtransfig.man: ../doc/transfig.1 X ln -s ../doc/transfig.1 transfig.man X cd doc/manual; make; latex manual; latex manual X Xclean:: X cd doc/manual; make clean X X# ------------------------------------------------------------------------- X# common rules for all Makefiles - do not edit X Xemptyrule:: X Xclean:: X $(RM_CMD) "#"* X XMakefile:: X -@if [ -f Makefile ]; then set -x; \ X $(RM) Makefile.bak; $(MV) Makefile Makefile.bak; \ X else exit 0; fi X $(IMAKE_CMD) -DTOPDIR=$(TOP) -DCURDIR=$(CURRENT_DIR) X Xtags:: X $(TAGS) -w *.[ch] X $(TAGS) -xw *.[ch] > TAGS X Xsaber: X # load $(ALLDEFINES) $(SRCS) X Xosaber: X # load $(ALLDEFINES) $(OBJS) X X# ------------------------------------------------------------------------- X# rules for building in SUBDIRS - do not edit X Xinstall:: X @case '${MFLAGS}' in *[ik]*) set +e;; esac; \ X for i in $(SUBDIRS) ;\ X do \ X (cd $$i ; echo "installing" "in $(CURRENT_DIR)/$$i..."; \ X $(MAKE) $(MFLAGS) DESTDIR='$(DESTDIR)' install); \ X done X Xinstall.man:: X @case '${MFLAGS}' in *[ik]*) set +e;; esac; \ X for i in $(SUBDIRS) ;\ X do \ X (cd $$i ; echo "installing man pages" "in $(CURRENT_DIR)/$$i..."; \ X $(MAKE) $(MFLAGS) DESTDIR='$(DESTDIR)' install.man); \ X done X Xclean:: X @case '${MFLAGS}' in *[ik]*) set +e;; esac; \ X for i in $(SUBDIRS) ;\ X do \ X (cd $$i ; echo "cleaning" "in $(CURRENT_DIR)/$$i..."; \ X $(MAKE) $(MFLAGS) RM_CMD='$(RM_CMD)' clean); \ X done X Xtags:: X @case '${MFLAGS}' in *[ik]*) set +e;; esac; \ X for i in $(SUBDIRS) ;\ X do \ X (cd $$i ; echo "tagging" "in $(CURRENT_DIR)/$$i..."; \ X $(MAKE) $(MFLAGS) TAGS='$(TAGS)' tags); \ X done X XMakefiles:: X @case '${MFLAGS}' in *[ik]*) set +e;; esac; \ X for i in $(SUBDIRS) ;\ X do \ X echo "making Makefiles in $(CURRENT_DIR)/$$i..."; \ X case "$$i" in \ X ./?*/?*/?*/?*) newtop=../../../../ sub=subsubsubsub;; \ X ./?*/?*/?*) newtop=../../../ sub=subsubsub;; \ X ./?*/?*) newtop=../../ sub=subsub;; \ X ./?*) newtop=../ sub=sub;; \ X */?*/?*/?*) newtop=../../../../ sub=subsubsubsub;; \ X */?*/?*) newtop=../../../ sub=subsubsub;; \ X */?*) newtop=../../ sub=subsub;; \ X *) newtop=../ sub=sub;; \ X esac; \ X case "$(TOP)" in \ X /?*) newtop= upprefix= ;; \ X *) upprefix=../ ;; \ X esac; \ X $(MAKE) $${sub}dirMakefiles UPPREFIX=$$upprefix NEWTOP=$$newtop \ X MAKEFILE_SUBDIR=$$i NEW_CURRENT_DIR=$(CURRENT_DIR)/$$i;\ X done X XsubdirMakefiles: X $(RM) $(MAKEFILE_SUBDIR)/Makefile.bak X -@if [ -f $(MAKEFILE_SUBDIR)/Makefile ]; then set -x; \ X $(MV) $(MAKEFILE_SUBDIR)/Makefile $(MAKEFILE_SUBDIR)/Makefile.bak; \ X else exit 0; fi X cd $(MAKEFILE_SUBDIR); $(IMAKE_CMD) -DTOPDIR=$(UPPREFIX)$(TOP) -DCURDIR=$(NEW_CURRENT_DIR); \ X $(MAKE) $(MFLAGS) Makefiles X XsubsubdirMakefiles: X $(RM) $(MAKEFILE_SUBDIR)/Makefile.bak X -@if [ -f $(MAKEFILE_SUBDIR)/Makefile ]; then set -x; \ X $(MV) $(MAKEFILE_SUBDIR)/Makefile $(MAKEFILE_SUBDIR)/Makefile.bak; \ X else exit 0; fi X cd $(MAKEFILE_SUBDIR); $(IMAKE_CMD) -DTOPDIR=$(UPPREFIX)$(UPPREFIX)$(TOP) -DCURDIR=$(NEW_CURRENT_DIR); \ X $(MAKE) $(MFLAGS) Makefiles X XsubsubsubdirMakefiles: X $(RM) $(MAKEFILE_SUBDIR)/Makefile.bak X -@if [ -f $(MAKEFILE_SUBDIR)/Makefile ]; then set -x; \ X $(MV) $(MAKEFILE_SUBDIR)/Makefile $(MAKEFILE_SUBDIR)/Makefile.bak; \ X else exit 0; fi X cd $(MAKEFILE_SUBDIR); $(IMAKE_CMD) -DTOPDIR=$(UPPREFIX)$(UPPREFIX)$(UPPREFIX)$(TOP) -DCURDIR=$(NEW_CURRENT_DIR); \ X $(MAKE) $(MFLAGS) Makefiles X XsubsubsubsubdirMakefiles: X $(RM) $(MAKEFILE_SUBDIR)/Makefile.bak X -@if [ -f $(MAKEFILE_SUBDIR)/Makefile ]; then set -x; \ X $(MV) $(MAKEFILE_SUBDIR)/Makefile $(MAKEFILE_SUBDIR)/Makefile.bak; \ X else exit 0; fi X cd $(MAKEFILE_SUBDIR); $(IMAKE_CMD) -DTOPDIR=$(UPPREFIX)$(UPPREFIX)$(UPPREFIX)$(UPPREFIX)$(TOP) -DCURDIR=$(NEW_CURRENT_DIR); \ X $(MAKE) $(MFLAGS) Makefiles X Xincludes:: X @case '${MFLAGS}' in *[ik]*) set +e;; esac; \ X for i in $(SUBDIRS) ;\ X do \ X (cd $$i ; echo including "in $(CURRENT_DIR)/$$i..."; \ X $(MAKE) $(MFLAGS) includes); \ X done X X# ------------------------------------------------------------------------- X# dependencies generated by makedepend X END_OF_FILE if test 12794 -ne `wc -c <'Makefile'`; then echo shar: \"'Makefile'\" unpacked with wrong size! fi # end of 'Makefile' fi if test -f 'doc/fig2dev.1' -a "${1}" != "-c" ; then echo shar: Will not clobber existing file \"'doc/fig2dev.1'\" else echo shar: Extracting \"'doc/fig2dev.1'\" \(11922 characters\) sed "s/^X//" >'doc/fig2dev.1' <<'END_OF_FILE' X.TH FIG2DEV 1 "Release 2.1(.8) (Protocol 2.1) Oct 1, 1993" X.SH NAME Xfig2dev \- translates Fig code to various graphics languages X X.SH SYNOPSIS X.B fig2dev X.B \-L X.I language X[ X.B \-m X.I mag X] [ X.B \-f X.I font X] [ X.B \-s X.I fsize X] [ X.I other options X] [ X\fIfig-file\fR [ \fIout-file\fR ] ] X X.SH DESCRIPTION X.I Fig2dev Xtranslates fig code in the named X.I fig-file Xinto the specified graphics X.I language Xand puts them in X.I out-file. XThe default X.I fig-file Xand X.I out-file Xare standard input and standard output, respectively X.LP XFig (Facility for Interactive Generation of figures) is a screen-oriented Xtool which allows the user to draw and manipulate objects interactively. XVarious versions of Fig run under the Suntools/Sunview window environment Xand under version 11 of the X Windows System. XFig2dev is compatible with Fig versions 1.3, 1.4, 2.0, and 2.1. X X.SH OPTIONS X.TP X.B \-L XSet the output graphics language. XValid languages are X\fBbox, epic, eepic, eepicemu, ibmgl, latex, null, pic, pictex, Xps, pstex, pstex_t, textyl,\fR Xand X.B tpic. X.TP X.B \-m XSet the magnification at which the figure is rendered to X.I mag. XThe default is 1.0. X.TP X.B \-f XSet the default font used for text objects to X.I font. XThe default is Roman; the format of this option depends on the graphics X.I language Xin use. XIn TeX-based languages, the font is the base of the name given in lfonts.tex, Xfor instance \"cmr\" for Roman, or \"tt\" for teletype. XIn PostScript, it is any font name known to the printer or interpreter. X.TP X.B \-s XSet the default font size (in points) for text objects to X.I fsize. XThe default is 11*mag, and thus is scaled by the \fB-m\fR option. XIf there is no scaling, the default font is eleven point Roman." X.TP X.B \-V XPrint the program version number only. X.TP X.I other options XThe other options are specific to the choice of graphics X.I language, Xas described below. X X.SH EPIC OPTIONS XEPIC is an enhancement to LaTeX picture drawing environment. XIt was developed by Sunil Podar of Department of Computer Science Xin S.U.N.Y at Stony Brook. X.LP XEEPIC is an extension to EPIC and LaTeX picture drawing environment Xwhich uses tpic specials as a graphics mechanism. XIt was written by Conrad Kwok of Division of XComputer Science at University of California, Davis. X.LP XEEPIC-EMU is an EEPIC emulation package which does not use tpic specials. X.TP X.B \-l XUse "\fB\\thicklines\fR" when width of the line is wider than X.I lwidth. XThe default is 2. X.TP X.B \-v XInclude comments in the output file. X.TP X.B \-P XGenerate a complete LaTeX file. In other words, the output file can be Xformatted without requiring any changes. The additional text inserted Xin the beginning and at the end of the file is controlled by the Xconfiguration parameter "Preamble" and "Postamble". X.TP X.B \-S XSet the scale to which the figure is rendered. XThis option automatically sets the X.I magnification Xand size to X.I scale X/ 12 and X.I scale Xrespectively. X.TP X.B \-W XEnable variable line width X.TP X.B \-w XDisable variable line width. Only "\fB\\thicklines\fR" and/or X"\fB\\thinlines\fR" commands will be generated in the output file. X.LP XWhen variable line width option is enabled, "\fB\\thinlines\fR" Xcommand is still used when line width is less than X\fILineThick\fR. One potential problem is that the width of X"\fB\\thinlines\fR" is 0.4pt Xbut the resolution of Fig is 1/80 inch (approx. 1pt). If X\fILineThick\fR is set to 2, normal lines will be drawn in 0.4pt Xwide lines but the next line width is already 2pt. One possible Xsolution is to set \fILineThick\fR to 1 and set the width of the Xthose lines you want to be drawn in "\fB\\thinlines\fR" to 0. X XDue to this problem, Variable line width \fIVarWidth\fR Xis defaulted to be false. X X.SH IBM-GL OPTIONS XIBM-GL (International Business Machines Graphics Language) is compatible Xwith HP-GL (Hewlett-Packard Graphics Language). X.TP X.B \-a XSelect ISO A4 (ANSI A) paper size if the default is ANSI A (ISO A4) paper size. X.TP X.B \-c XGenerate instructions for an IBM 6180 Color Plotter Xwith (without) an IBM Graphics Enhancement Cartridge (IBM-GEC). X.TP X.B \-d XRestrict plotting to a rectangular area of the plotter paper which has Xa lower left hand corner at X.I (xll,yll) Xand a upper right hand corner at X.I (xur,yur). XAll four numbers are in inches and follow \fB-d\fR in a comma-sparated list - X.I xll,yll,xur,yur X- with no spaces between them. X.TP X.B \-f XLoad text character specifications from the table in the X.I fonts Xfile. XThe table must have 36 entries - one for each font plus a default. XEach entry consists of 5 numbers Xwhich specify the X1.) standard character set (0 - 4, 6 - 9, 30 - 39), X2.) alternate character set (0 - 4, 6 - 9, 30 - 39), X3.) character slant angle (degrees), X4.) character width scale factor and X5.) character height scale factor. X.TP X.B \-l XLoad area fill line patterns from the table in the X.I patterns Xfile. XThe table must have 21 entries - one for each of the area fill patterns. XEach entry consists of 5 numbers which specify the X1.) pattern number (-1 - 6), X2.) pattern length (inches), X3.) fill type (1 - 5), X4.) fill spacing (inches) and X5.) fill angle (degrees). X.TP X.B \-m XThe magnification may appear as the first element in a comma sepatated list - X.I mag,x0,y0 X- where the second and third parameters specify an offset in inches. X.TP X.B \-p XLoad plotter pen specifications from the table in the X.I pens Xfile. XThe table must have 9 entries - one for each color plus a default. XEach entry consists of 2 numbers which specify the X1.) pen number (1 - 8) and X2.) pen thickness (millimeters). X.TP X.B \-P XRotate the figure to portrait mode. The default is landscape mode. X.TP X.B \-S XSet the pen speed to X.I speed X(centimeters/second). X.TP X.B \-v XPlot the figure upside-down in portrait mode or backwards in landscape mode. XThis allows you to write on the top surface of overhead transparencies without Xdisturbing the plotter ink on the bottom surface. X.LP XFig2dev may be installed with either ANSI A or ISO A4 default paper size. XThe \fB-a\fR option selects the alternate paper size. XFig2dev does not fill closed splines. XThe IBM-GEC is required to fill other polygons. XFig2dev may be installed for plotters with or without the IBM-GEC. XThe \fB-c\fR option selects the alternate instruction set. X X.SH LATEX OPTIONS X.TP X.B \-l XSets the threshold between LaTeX thin and thick lines to X.I lwidth Xpixels. XLaTeX supports only two different line width: \\thinlines and \\thicklines. XLines of width greater than X.I lwidth Xpixels are drawn as \\thicklines. XAlso affects the size of dots in dotted line style. XThe default is 1. X.TP X.B \-d XSet a separate magnification for the length of line dashes to X.I dmag. X.TP X.B \-v XVerbose mode. X.LP XLaTeX cannot accurately represent all the graphics objects which can Xbe described by Fig. XFor example, the possible slopes which lines may have are limited. XSome objects, such as spline curves, cannot be drawn at all. XFig2latex chooses the closest possible line slope, and prints error Xmessages when objects cannot be drawn accurately X X.SH PIC OPTIONS X.TP X.B -p XEnables the use of certain PIC extensions which are known to work with Xthe groff package; compatibility with DWB PIC is unknown. XThe extensions enabled by each option are: X.LP X.TP X.B arc XAllow ARC_BOX i.e. use rounded corners X.TP X.B line XUse the 'line_thickness' value X.TP X.B fill XAllow ellipses to be filled X.TP X.B all XUse all of the above X.TP X.B psfont XDon't convert Postscript fonts generic type (useful for files going to be XDitroff'ed for and printed on PS printer). DWB-compatible. X.TP X.B allps XUse all of the above (i.e. "all" + "psfont") X.EP X.EP X X.SH PICTEX OUTPUT XIn order to include PiCTeX pictures into a document, it is necessary to Xload the PiCTeX macros. X.LP XPiCTeX uses TeX integer register arithmetic to generate curves, Xand so it is very slow. XPiCTeX draws curves by \fB\\put\fR-ing the \fIpsymbol\fR repeatedly, Xand so requires a large amount of TeX's internal memory, Xand generates large DVI files. XThe size of TeX's memory limits the number of plot symbols in a picture. XAs a result, it is best to use PiCTeX to generate small pictures. X X.SH POSTSCRIPT OPTIONS XWith PostScript, Fig can be used to create large posters. The figure Xwill be created by printing multiple pages which can be glued together. XDue to memory limitations of most laser printers, the figure should not Xbe too complicated. Great for text with very big letters. X.LP XText can now include various ISO-character codes above 0x7f, which is Xuseful for language specific characters to be printed directly. XNot all ISO-characters are implemented. X.LP XColor support: Colored objects created by Fig can be printed Xon a color postscript printer. Currently 8 colors are Xsupported: black, blue, green, cyan, red, magenta, yellow, white. XOn a monochrome printer, colored objects will be mapped into different Xgrayscales. XFilled objects are printed using the given grayscale. If filled Xwith grayscale set to 100%, the object will be filled with the same Xcolor as the enclosing line. X.TP X.B -c Xoption centers the figure on the page. XThe centering may not be accurate if there are texts in the X.I fig_file Xthat extends too far to the right of other objects. X.TP X.B -l dummy_arg XRotate figure to landscape mode. The dummy argument is ignored, Xbut must appear on the command line for reasons of compatibility. X.TP X.B -P Xindicates that the figure describes a full page which will not Xnecessarily be inserted into a document, but can be sent directly Xto a PS printer. XThis ensures that a showpage command is inserted at the end of Xthe figure, and inhibits translation of the figure coordinate system. X.LP X X.SH PSTEX OPTIONS X.TP XThe X.B pstex Xlanguage is a variant of X.B ps Xwhich suppresses formatted (special) text. XThe X.B pstex_t Xlanguage has the complementary behavior: it generates only LaTeX commands Xnecessary to position special text, and to overlay the XPostScript file generated using X.B pstex. XThese two drivers can be used to generate a figure which combines the Xflexibility of PostScript graphics with LaTeX text formatting of Xspecial text. X.TP XThe X.B pstex_t Xoption X.B -p file Xspecifies the name of the PostScript file to be overlaid. XIf not set or its value is null then no PS file will be inserted. X.LP X X.SH TEXTYL OPTIONS XThere are no TeXtyl-specific options. X X.SH TPIC OPTIONS XThere are no tpic-specific options. X X.SH "SEE ALSO" X[x]fig(1), Xpic(1) Xpic2fig(1), Xtransfig(1) X.SH COPYRIGHT XCopyright (c) 1985 Supoj Sutantavibul X.br XCopyright (c) 1991 Micah Beck X.LP XPermission to use, copy, modify, distribute, and sell this software and its Xdocumentation for any purpose is hereby granted without fee, provided that Xthe above copyright notice appear in all copies and that both that Xcopyright notice and this permission notice appear in supporting Xdocumentation. The authors make no representations about the suitability Xof this software for any purpose. It is provided "as is" without express Xor implied warranty. X.LP XTHE AUTHORS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, XINCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO XEVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL, INDIRECT OR XCONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, XDATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER XTORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR XPERFORMANCE OF THIS SOFTWARE. X.SH AUTHORS XMicah Beck X.br XCornell University X.br XSept 28 1990 X.sp Xand Frank Schmuck (then of Cornell University) X.br Xand Conrad Kwok (then of U.C. Davis). X.sp Xdrivers contributed by X.br XJose Alberto Fernandez R. (U. of Maryland) X.br Xand Gary Beihl (MCC) X.sp XColor support, ISO-character encoding and poster support by X.br XHerbert Bauer (heb@regent.e-technik.tu-muenchen.de) X.sp XModified from f2p (fig to PIC), by the author of Fig X.br XSupoj Sutanthavibul (supoj@sally.utexas.edu) X.br XUniversity of Texas at Austin. X END_OF_FILE if test 11922 -ne `wc -c <'doc/fig2dev.1'`; then echo shar: \"'doc/fig2dev.1'\" unpacked with wrong size! fi # end of 'doc/fig2dev.1' fi if test -f 'fig2dev/bound.c' -a "${1}" != "-c" ; then echo shar: Will not clobber existing file \"'fig2dev/bound.c'\" else echo shar: Extracting \"'fig2dev/bound.c'\" \(12109 characters\) sed "s/^X//" >'fig2dev/bound.c' <<'END_OF_FILE' X/* X * TransFig: Facility for Translating Fig code X * Copyright (c) 1985 Supoj Sutantavibul X * Copyright (c) 1991 Micah Beck X * X * Permission to use, copy, modify, distribute, and sell this software and its X * documentation for any purpose is hereby granted without fee, provided that X * the above copyright notice appear in all copies and that both that X * copyright notice and this permission notice appear in supporting X * documentation. The authors make no representations about the suitability X * of this software for any purpose. It is provided "as is" without express X * or implied warranty. X * X * THE AUTHORS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, X * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO X * EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL, INDIRECT OR X * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, X * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER X * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR X * PERFORMANCE OF THIS SOFTWARE. X * X */ X X#include X#include X#include "pi.h" X#include "object.h" X X#define Ninety_deg M_PI_2 X#define One_eighty_deg M_PI X#define Two_seventy_deg (M_PI + M_PI_2) X#define Three_sixty_deg (M_PI + M_PI) X#define round(x) ((int) ((x) + ((x >= 0)? 0.5: -0.5))) X#define half(z1 ,z2) ((z1+z2)/2.0) X#define max(a, b) (((a) > (b)) ? (a) : (b)) X#define min(a, b) (((a) < (b)) ? (a) : (b)) X Xarc_bound(arc, xmin, ymin, xmax, ymax) XF_arc *arc; Xint *xmin, *ymin, *xmax, *ymax; X{ X double alpha, beta; X double dx, dy, radius; X int bx, by, sx, sy; X X dx = arc->point[0].x - arc->center.x; X dy = arc->center.y - arc->point[0].y; X alpha = atan2(dy, dx); X if (alpha < 0.0) alpha += Three_sixty_deg; X /* compute_angle returns value between 0 to 2PI */ X X radius = hypot(dx, dy); X X dx = arc->point[2].x - arc->center.x; X dy = arc->center.y - arc->point[2].y; X beta = atan2(dy, dx); X if (beta < 0.0) beta += Three_sixty_deg; X X bx = max(arc->point[0].x, arc->point[1].x); X bx = max(arc->point[2].x, bx); X by = max(arc->point[0].y, arc->point[1].y); X by = max(arc->point[2].y, by); X sx = min(arc->point[0].x, arc->point[1].x); X sx = min(arc->point[2].x, sx); X sy = min(arc->point[0].y, arc->point[1].y); X sy = min(arc->point[2].y, sy); X X if (arc->direction == 1) { /* counter clockwise */ X if (alpha > beta) { X if (alpha <= 0 || 0 <= beta) X bx = (int)(arc->center.x + radius + 1.0); X if (alpha <= Ninety_deg || Ninety_deg <= beta) X sy = (int)(arc->center.y - radius - 1.0); X if (alpha <= One_eighty_deg || One_eighty_deg <= beta) X sx = (int)(arc->center.x - radius - 1.0); X if (alpha <= Two_seventy_deg || Two_seventy_deg <= beta) X by = (int)(arc->center.y + radius + 1.0); X } X else { X if (0 <= beta && alpha <= 0) X bx = (int)(arc->center.x + radius + 1.0); X if (Ninety_deg <= beta && alpha <= Ninety_deg) X sy = (int)(arc->center.y - radius - 1.0); X if (One_eighty_deg <= beta && alpha <= One_eighty_deg) X sx = (int)(arc->center.x - radius - 1.0); X if (Two_seventy_deg <= beta && alpha <= Two_seventy_deg) X by = (int)(arc->center.y + radius + 1.0); X } X } X else { /* clockwise */ X if (alpha > beta) { X if (beta <= 0 && 0 <= alpha) X bx = (int)(arc->center.x + radius + 1.0); X if (beta <= Ninety_deg && Ninety_deg <= alpha) X sy = (int)(arc->center.y - radius - 1.0); X if (beta <= One_eighty_deg && One_eighty_deg <= alpha) X sx = (int)(arc->center.x - radius - 1.0); X if (beta <= Two_seventy_deg && Two_seventy_deg <= alpha) X by = (int)(arc->center.y + radius + 1.0); X } X else { X if (0 <= alpha || beta <= 0) X bx = (int)(arc->center.x + radius + 1.0); X if (Ninety_deg <= alpha || beta <= Ninety_deg) X sy = (int)(arc->center.y - radius - 1.0); X if (One_eighty_deg <= alpha || beta <= One_eighty_deg) X sx = (int)(arc->center.x - radius - 1.0); X if (Two_seventy_deg <= alpha || beta <= Two_seventy_deg) X by = (int)(arc->center.y + radius + 1.0); X } X } X *xmax = bx; *ymax = by; X *xmin = sx; *ymin = sy; X } X Xcompound_bound(compound, xmin, ymin, xmax, ymax, include) XF_compound *compound; Xint *xmin, *ymin, *xmax, *ymax; Xint include; X{ X F_arc *a; X F_ellipse *e; X F_compound *c; X F_spline *s; X F_line *l; X F_text *t; X int bx, by, sx, sy, first = 1; X int llx, lly, urx, ury; X X while(compound != NULL) X { X for (a = compound->arcs; a != NULL; a = a->next) { X arc_bound(a, &sx, &sy, &bx, &by); X if (first) { X first = 0; X llx = sx; lly = sy; X urx = bx; ury = by; X } X else { X llx = min(llx, sx); lly = min(lly, sy); X urx = max(urx, bx); ury = max(ury, by); X } X } X X for (c = compound->compounds; c != NULL; c = c->next) { X compound_bound(c, &sx, &sy, &bx, &by); X if (first) { X first = 0; X llx = sx; lly = sy; X urx = bx; ury = by; X } X else { X llx = min(llx, sx); lly = min(lly, sy); X urx = max(urx, bx); ury = max(ury, by); X } X } X X for (e = compound->ellipses; e != NULL; e = e->next) { X ellipse_bound(e, &sx, &sy, &bx, &by); X if (first) { X first = 0; X llx = sx; lly = sy; X urx = bx; ury = by; X } X else { X llx = min(llx, sx); lly = min(lly, sy); X urx = max(urx, bx); ury = max(ury, by); X } X } X X for (l = compound->lines; l != NULL; l = l->next) { X line_bound(l, &sx, &sy, &bx, &by); X if (first) { X first = 0; X llx = sx; lly = sy; X urx = bx; ury = by; X } X else { X llx = min(llx, sx); lly = min(lly, sy); X urx = max(urx, bx); ury = max(ury, by); X } X } X X for (s = compound->splines; s != NULL; s = s->next) { X spline_bound(s, &sx, &sy, &bx, &by); X if (first) { X first = 0; X llx = sx; lly = sy; X urx = bx; ury = by; X } X else { X llx = min(llx, sx); lly = min(lly, sy); X urx = max(urx, bx); ury = max(ury, by); X } X } X X for (t = compound->texts; t != NULL; t = t->next) { X text_bound(t, &sx, &sy, &bx, &by, include); X if (first) { X first = 0; X llx = sx; lly = sy; X urx = bx; ury = by; X } X else { X llx = min(llx, sx); lly = min(lly, sy); X urx = max(urx, bx); ury = max(ury, by); X } X } X compound = compound->next; X } X X *xmin = llx; *ymin = lly; X *xmax = urx; *ymax = ury; X } X Xellipse_bound(e, xmin, ymin, xmax, ymax) XF_ellipse *e; Xint *xmin, *ymin, *xmax, *ymax; X{ X *xmin = e->center.x - e->radiuses.x; X *ymin = e->center.y - e->radiuses.y; X *xmax = e->center.x + e->radiuses.x; X *ymax = e->center.y + e->radiuses.y; X } X Xline_bound(l, xmin, ymin, xmax, ymax) XF_line *l; Xint *xmin, *ymin, *xmax, *ymax; X{ X points_bound(l->points, xmin, ymin, xmax, ymax); X } X Xspline_bound(s, xmin, ymin, xmax, ymax) XF_spline *s; Xint *xmin, *ymin, *xmax, *ymax; X{ X if (int_spline(s)) { X int_spline_bound(s, xmin, ymin, xmax, ymax); X } X else { X normal_spline_bound(s, xmin, ymin, xmax, ymax); X } X } X Xint_spline_bound(s, xmin, ymin, xmax, ymax) XF_spline *s; Xint *xmin, *ymin, *xmax, *ymax; X{ X F_point *p1, *p2; X F_control *cp1, *cp2; X double x0, y0, x1, y1, x2, y2, x3, y3, sx1, sy1, sx2, sy2; X double tx, ty, tx1, ty1, tx2, ty2; X double sx, sy, bx, by; X X p1 = s->points; X sx = bx = p1->x; X sy = by = p1->y; X cp1 = s->controls; X for (p2 = p1->next, cp2 = cp1->next; p2 != NULL; X p1 = p2, cp1 = cp2, p2 = p2->next, cp2 = cp2->next) { X x0 = p1->x; y0 = p1->y; X x1 = cp1->rx; y1 = cp1->ry; X x2 = cp2->lx; y2 = cp2->ly; X x3 = p2->x; y3 = p2->y; X tx = half(x1, x2); ty = half(y1, y2); X sx1 = half(x0, x1); sy1 = half(y0, y1); X sx2 = half(sx1, tx); sy2 = half(sy1, ty); X tx2 = half(x2, x3); ty2 = half(y2, y3); X tx1 = half(tx2, tx); ty1 = half(ty2, ty); X X sx = min(x0, sx); sy = min(y0, sy); X sx = min(sx1, sx); sy = min(sy1, sy); X sx = min(sx2, sx); sy = min(sy2, sy); X sx = min(tx1, sx); sy = min(ty1, sy); X sx = min(tx2, sx); sy = min(ty2, sy); X sx = min(x3, sx); sy = min(y3, sy); X X bx = max(x0, bx); by = max(y0, by); X bx = max(sx1, bx); by = max(sy1, by); X bx = max(sx2, bx); by = max(sy2, by); X bx = max(tx1, bx); by = max(ty1, by); X bx = max(tx2, bx); by = max(ty2, by); X bx = max(x3, bx); by = max(y3, by); X } X *xmin = round(sx); X *ymin = round(sy); X *xmax = round(bx); X *ymax = round(by); X } X Xnormal_spline_bound(s, xmin, ymin, xmax, ymax) XF_spline *s; Xint *xmin, *ymin, *xmax, *ymax; X{ X F_point *p; X double cx1, cy1, cx2, cy2, cx3, cy3, cx4, cy4; X double x1, y1, x2, y2, sx, sy, bx, by; X double px, py, qx, qy; X X p = s->points; X x1 = p->x; y1 = p->y; X p = p->next; X x2 = p->x; y2 = p->y; X cx1 = (x1 + x2) / 2.0; cy1 = (y1 + y2) / 2.0; X cx2 = (cx1 + x2) / 2.0; cy2 = (cy1 + y2) / 2.0; X if (closed_spline(s)) { X x1 = (cx1 + x1) / 2.0; X y1 = (cy1 + y1) / 2.0; X } X sx = min(x1, cx2); sy = min(y1, cy2); X bx = max(x1, cx2); by = max(y1, cy2); X X for (p = p->next; p != NULL; p = p->next) { X x1 = x2; y1 = y2; X x2 = p->x; y2 = p->y; X cx4 = (x1 + x2) / 2.0; cy4 = (y1 + y2) / 2.0; X cx3 = (x1 + cx4) / 2.0; cy3 = (y1 + cy4) / 2.0; X cx2 = (cx4 + x2) / 2.0; cy2 = (cy4 + y2) / 2.0; X X px = min(cx2, cx3); py = min(cy2, cy3); X qx = max(cx2, cx3); qy = max(cy2, cy3); X X sx = min(sx, px); sy = min(sy, py); X bx = max(bx, qx); by = max(by, qy); X } X if (closed_spline(s)) { X *xmin = round(sx); *ymin = round(sy); X *xmax = round(bx); *ymax = round(by); X } X else { X *xmin = round(min(sx, x2)); *ymin = round(min(sy, y2)); X *xmax = round(max(bx, x2)); *ymax = round(max(by, y2)); X } X } X Xdouble rot_x(x,y,angle) Xdouble x,y,angle; X{ X return(x*cos(-angle)-y*sin(-angle)); X} X Xdouble rot_y(x,y,angle) Xdouble x,y,angle; X{ X return(x*sin(-angle)+y*cos(-angle)); X} X X Xtext_bound(t, xmin, ymin, xmax, ymax, include) XF_text *t; Xint *xmin, *ymin, *xmax, *ymax; Xint include; X{ X double dx1, dx2, dx3, dx4, dy1, dy2, dy3, dy4; X X if (t->type == T_CENTER_JUSTIFIED) { X dx1 = (t->length/2); dy1 = 0.0; X dx2 = -(t->length/2); dy2 = 0.0; X dx3 = (t->length/2); dy3 = -t->height; X dx4 = -(t->length/2); dy4 = -t->height; X } else if (t->type == T_RIGHT_JUSTIFIED) { X dx1 = 0.0; dy1 = 0.0; X dx2 = -t->length; dy2 = 0.0; X dx3 = 0.0; dy3 = -t->height; X dx4 = -t->length; dy4 = -t->height; X } else { X dx1 = (include ? t->length : 0); dy1 = 0.0; X dx2 = 0.0; dy2 = 0.0; X dx3 = (include ? t->length : 0); dy3 = -t->height; X dx4 = 0.0; dy4 = -t->height; X } X *xmax= t->base_x + X max( max( rot_x(dx1,dy1,t->angle), rot_x(dx2,dy2,t->angle) ), X max( rot_x(dx3,dy3,t->angle), rot_x(dx4,dy4,t->angle) ) ); X *ymax= t->base_y + X max( max( rot_y(dx1,dy1,t->angle), rot_y(dx2,dy2,t->angle) ), X max( rot_y(dx3,dy3,t->angle), rot_y(dx4,dy4,t->angle) ) ); X X *xmin= t->base_x + X min( min( rot_x(dx1,dy1,t->angle), rot_x(dx2,dy2,t->angle) ), X min( rot_x(dx3,dy3,t->angle), rot_x(dx4,dy4,t->angle) ) ); X *ymin= t->base_y + X min( min( rot_y(dx1,dy1,t->angle), rot_y(dx2,dy2,t->angle) ), X min( rot_y(dx3,dy3,t->angle), rot_y(dx4,dy4,t->angle) ) ); X } X Xpoints_bound(points, xmin, ymin, xmax, ymax) XF_point *points; Xint *xmin, *ymin, *xmax, *ymax; X{ X int bx, by, sx, sy; X F_point *p; X X bx = sx = points->x; by = sy = points->y; X for (p = points->next; p != NULL; p = p->next) { X sx = min(sx, p->x); sy = min(sy, p->y); X bx = max(bx, p->x); by = max(by, p->y); X } X *xmin = sx; *ymin = sy; X *xmax = bx; *ymax = by; X } X Xcontrol_points_bound(cps, xmin, ymin, xmax, ymax) XF_control *cps; Xint *xmin, *ymin, *xmax, *ymax; X{ X F_control *c; X double bx, by, sx, sy; X X bx = sx = cps->lx; X by = sy = cps->ly; X sx = min(sx, cps->rx); sy = min(sy, cps->ry); X bx = max(bx, cps->rx); by = max(by, cps->ry); X for (c = cps->next; c != NULL; c = c->next) { X sx = min(sx, c->lx); sy = min(sy, c->ly); X bx = max(bx, c->lx); by = max(by, c->ly); X sx = min(sx, c->rx); sy = min(sy, c->ry); X bx = max(bx, c->rx); by = max(by, c->ry); X } X *xmin = round(sx); *ymin = round(sy); X *xmax = round(bx); *ymax = round(by); X } END_OF_FILE if test 12109 -ne `wc -c <'fig2dev/bound.c'`; then echo shar: \"'fig2dev/bound.c'\" unpacked with wrong size! fi # end of 'fig2dev/bound.c' fi if test -f 'fig2dev/read1_3.c' -a "${1}" != "-c" ; then echo shar: Will not clobber existing file \"'fig2dev/read1_3.c'\" else echo shar: Extracting \"'fig2dev/read1_3.c'\" \(10940 characters\) sed "s/^X//" >'fig2dev/read1_3.c' <<'END_OF_FILE' X/* X * TransFig: Facility for Translating Fig code X * Copyright (c) 1985 Supoj Sutantavibul X * Copyright (c) 1991 Micah Beck X * X * Permission to use, copy, modify, distribute, and sell this software and its X * documentation for any purpose is hereby granted without fee, provided that X * the above copyright notice appear in all copies and that both that X * copyright notice and this permission notice appear in supporting X * documentation. The authors make no representations about the suitability X * of this software for any purpose. It is provided "as is" without express X * or implied warranty. X * X * THE AUTHORS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, X * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO X * EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL, INDIRECT OR X * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, X * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER X * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR X * PERFORMANCE OF THIS SOFTWARE. X * X */ X X/*******************************************************************/ X/*************** Read version 1.3 format ***************/ X/*******************************************************************/ X#include X#include X#include X#include X#include "alloc.h" X#include "object.h" X X/******* Fig 1.3 subtype of objects *******/ X#define DRAW_ELLIPSE_BY_RAD 1 X#define DRAW_ELLIPSE_BY_DIA 2 X#define DRAW_CIRCLE_BY_RAD 3 X#define DRAW_CIRCLE_BY_DIA 4 X#define DRAW_CIRCULAR_ARC 5 X#define DRAW_POLYLINE 6 X#define DRAW_BOX 7 X#define DRAW_POLYGON 8 X#define DRAW_TEXT 9 X#define DRAW_SPLINE 10 X#define DRAW_CLOSEDSPLINE 11 X#define DRAW_COMPOUND 13 X Xextern F_arrow *forward_arrow(), *backward_arrow(); Xextern int figure_modified; Xextern int errno; Xextern char *sys_errlist[]; Xextern int sys_nerr, errno; X Xstatic F_ellipse *read_ellipseobject(); Xstatic F_line *read_lineobject(); Xstatic F_text *read_textobject(); Xstatic F_spline *read_splineobject(); Xstatic F_arc *read_arcobject(); Xstatic F_compound *read_compoundobject(); X Xextern int line_no; Xextern int num_object; X Xint Xread_1_3_objects(fp, obj) XFILE *fp; XF_compound *obj; X{ X F_ellipse *e, *le = NULL; X F_line *l, *ll = NULL; X F_text *t, *lt = NULL; X F_spline *s, *ls = NULL; X F_arc *a, *la = NULL; X F_compound *c, *lc = NULL; X int n; X int object, pixperinch, canvaswid, canvasht, coord_sys; X X n = fscanf(fp,"%d%d%d%d\n", &pixperinch, &coord_sys, &canvaswid, &canvasht); X if (n != 4) { X put_msg("Incorrect format in the first line in input file"); X return(-1); X } X obj->nwcorner.x = pixperinch; X obj->nwcorner.y = coord_sys; X while (fscanf(fp, "%d", &object) == 1) { X switch (object) { X case O_POLYLINE : X if ((l = read_lineobject(fp)) == NULL) return(-1); X if (ll) X ll = (ll->next = l); X else X ll = obj->lines = l; X num_object++; X break; X case O_SPLINE : X if ((s = read_splineobject(fp)) == NULL) return(-1); X if (ls) X ls = (ls->next = s); X else X ls = obj->splines = s; X num_object++; X break; X case O_ELLIPSE : X if ((e = read_ellipseobject(fp)) == NULL) return(-1); X if (le) X le = (le->next = e); X else X le = obj->ellipses = e; X num_object++; X break; X case O_ARC : X if ((a = read_arcobject(fp)) == NULL) return(-1); X if (la) X la = (la->next = a); X else X la = obj->arcs = a; X num_object++; X break; X case O_TEXT : X if ((t = read_textobject(fp)) == NULL) return(-1); X if (lt) X lt = (lt->next = t); X else X lt = obj->texts = t; X num_object++; X break; X case O_COMPOUND : X if ((c = read_compoundobject(fp)) == NULL) return(-1); X if (lc) X lc = (lc->next = c); X else X lc = obj->compounds = c; X num_object++; X break; X default: X put_msg("Incorrect object code %d", object); X return(-1); X } /* switch */ X } /* while */ X if (feof(fp)) X return(0); X else X return(errno); X } X Xstatic F_arc * Xread_arcobject(fp) XFILE *fp; X{ X F_arc *a; X int f, b, h, w, n; X X Arc_malloc(a); X a->type = T_3_POINTS_ARC; X a->color = BLACK_COLOR; X a->depth = 0; X a->pen = 0; X a->for_arrow = NULL; X a->back_arrow = NULL; X a->next = NULL; X n = fscanf(fp, " %d %d %d %lf %d %d %d %d %d %lf %lf %d %d %d %d %d %d\n", X &a->type, &a->style, &a->thickness, X &a->style_val, &a->direction, &f, &b, X &h, &w, &a->center.x, &a->center.y, X &a->point[0].x, &a->point[0].y, X &a->point[1].x, &a->point[1].y, X &a->point[2].x, &a->point[2].y); X if (n != 17) { X put_msg("incomplete arc data"); X free((char*)a); X return(NULL); X } X if (f) { X a->for_arrow = forward_arrow(); X a->for_arrow->wid = w; X a->for_arrow->ht = h; X } X if (b) { X a->back_arrow = backward_arrow(); X a->back_arrow->wid = w; X a->back_arrow->ht = h; X } X return(a); X } X Xstatic F_compound * Xread_compoundobject(fp) XFILE *fp; X{ X F_arc *a, *la = NULL; X F_ellipse *e, *le = NULL; X F_line *l, *ll = NULL; X F_spline *s, *ls = NULL; X F_text *t, *lt = NULL; X F_compound *com, *c, *lc = NULL; X int n, object; X X Compound_malloc(com); X com->arcs = NULL; X com->ellipses = NULL; X com->lines = NULL; X com->splines = NULL; X com->texts = NULL; X com->compounds = NULL; X com->next = NULL; X n = fscanf(fp, " %d %d %d %d\n", &com->nwcorner.x, &com->nwcorner.y, X &com->secorner.x, &com->secorner.y); X if (n != 4) { X put_msg("Incorrect compound object format"); X return(NULL); X } X while (fscanf(fp, "%d", &object) == 1) { X switch (object) { X case O_POLYLINE : X if ((l = read_lineobject(fp)) == NULL) { X free_line(&l); X return(NULL); X } X if (ll) X ll = (ll->next = l); X else X ll = com->lines = l; X break; X case O_SPLINE : X if ((s = read_splineobject(fp)) == NULL) { X free_spline(&s); X return(NULL); X } X if (ls) X ls = (ls->next = s); X else X ls = com->splines = s; X break; X case O_ELLIPSE : X if ((e = read_ellipseobject(fp)) == NULL) { X free_ellipse(&e); X return(NULL); X } X if (le) X le = (le->next = e); X else X le = com->ellipses = e; X break; X case O_ARC : X if ((a = read_arcobject(fp)) == NULL) { X free_arc(&a); X return(NULL); X } X if (la) X la = (la->next = a); X else X la = com->arcs = a; X break; X case O_TEXT : X if ((t = read_textobject(fp)) == NULL) { X free_text(&t); X return(NULL); X } X if (lt) X lt = (lt->next = t); X else X lt = com->texts = t; X break; X case O_COMPOUND : X if ((c = read_compoundobject(fp)) == NULL) { X free_compound(&c); X return(NULL); X } X if (lc) X lc = (lc->next = c); X else X lc = com->compounds = c; X break; X case O_END_COMPOUND : X return(com); X } /* switch */ X } X if (feof(fp)) X return(com); X else { X put_msg("Format error: %s", sys_errlist[errno]); X return(NULL); X } X } X Xstatic F_ellipse * Xread_ellipseobject(fp) XFILE *fp; X{ X F_ellipse *e; X int n, t; X X Ellipse_malloc(e); X e->color = BLACK_COLOR; X e->angle = 0.0; X e->depth = 0; X e->pen = 0; X e->area_fill = 0; X e->next = NULL; X n = fscanf(fp," %d %d %d %lf %d %d %d %d %d %d %d %d %d\n", X &t, &e->style, X &e->thickness, &e->style_val, &e->direction, X &e->center.x, &e->center.y, X &e->radiuses.x, &e->radiuses.y, X &e->start.x, &e->start.y, X &e->end.x, &e->end.y); X if (n != 13) { X put_msg("incomplete ellipse data"); X free((char*)e); X return(NULL); X } X if (t == DRAW_ELLIPSE_BY_RAD) X e->type = T_ELLIPSE_BY_RAD; X else if (t == DRAW_ELLIPSE_BY_DIA) X e->type = T_ELLIPSE_BY_DIA; X else if (t == DRAW_CIRCLE_BY_RAD) X e->type = T_CIRCLE_BY_RAD; X else X e->type = T_CIRCLE_BY_DIA; X return(e); X } X Xstatic F_line * Xread_lineobject(fp) XFILE *fp; X{ X F_line *l; X F_point *p, *q; X int f, b, h, w, n, t, x, y; X X Line_malloc(l); X l->color = BLACK_COLOR; X l->depth = 0; X l->pen = 0; X l->area_fill = 0; X l->for_arrow = NULL; X l->back_arrow = NULL; X l->next = NULL; X l->points = Point_malloc(p); X n = fscanf(fp, " %d %d %d %lf %d %d %d %d %d %d", &t, X &l->style, &l->thickness, &l->style_val, X &f, &b, &h, &w, &p->x, &p->y); X if (n != 10) { X put_msg("incomplete line data"); X free((char*)l); X return(NULL); X } X if (t == DRAW_POLYLINE) X l->type = T_POLYLINE; X else if (t == DRAW_POLYGON) X l->type = T_POLYGON; X else X l->type = T_BOX; X if (f) { X l->for_arrow = forward_arrow(); X l->for_arrow->wid = w; X l->for_arrow->ht = h; X } X if (b) { X l->back_arrow = backward_arrow(); X l->back_arrow->wid = w; X l->back_arrow->ht = h; X } X for (;;) { X if (fscanf(fp, " %d %d", &x, &y) != 2) { X put_msg("incomplete line object"); X free_linestorage(l); X return(NULL); X } X if (x == 9999) break; X Point_malloc(q); X q->x = x; X q->y = y; X q->next = NULL; X p->next = q; X p = q; X } X return(l); X } X Xstatic F_spline * Xread_splineobject(fp) XFILE *fp; X{ X F_spline *s; X F_point *p, *q; X int f, b, h, w, n, t, x, y; X X Spline_malloc(s); X s->color = BLACK_COLOR; X s->depth = 0; X s->pen = 0; X s->area_fill = 0; X s->for_arrow = NULL; X s->back_arrow = NULL; X s->controls = NULL; X s->next = NULL; X s->points = Point_malloc(p); X n = fscanf(fp, " %d %d %d %lf %d %d %d %d %d %d", X &t, &s->style, &s->thickness, &s->style_val, X &f, &b, X &h, &w, &p->x, &p->y); X if (n != 10) { X put_msg("incomplete spline data"); X free((char*)s); X return(NULL); X } X if (t == DRAW_CLOSEDSPLINE) X s->type = T_CLOSED_NORMAL; X else X s->type = T_OPEN_NORMAL; X if (f) { X s->for_arrow = forward_arrow(); X s->for_arrow->wid = w; X s->for_arrow->ht = h; X } X if (b) { X s->back_arrow = backward_arrow(); X s->back_arrow->wid = w; X s->back_arrow->ht = h; X } X for (;;) { X if (fscanf(fp, " %d %d", &x, &y) != 2) { X put_msg("incomplete spline object"); X free_splinestorage(s); X return(NULL); X }; X if (x == 9999) break; X Point_malloc(q); X q->x = x; X q->y = y; X q->next = NULL; X p->next = q; X p = q; X } X return(s); X } X Xstatic F_text * Xread_textobject(fp) XFILE *fp; X{ X F_text *t; X int n; X char buf[128]; X X Text_malloc(t); X t->type = T_LEFT_JUSTIFIED; X t->flags = 0; X t->color = BLACK_COLOR; X t->depth = 0; X t->pen = 0; X t->angle = 0.0; X t->next = NULL; X n = fscanf(fp," %d %d %d %d %d %d %d %[^\n]", &t->font, X &t->size, &t->flags, &t->height, &t->length, X &t->base_x, &t->base_y, buf); X if (n != 8) { X put_msg("incomplete text data"); X free((char*)t); X return(NULL); X } X t->cstring = (char *) calloc((unsigned)(strlen(buf)+1), sizeof(char)); X if (t->cstring == NULL) { X put_msg(Err_mem); X free((char*) t); X return(NULL); X } X (void)strcpy(t->cstring, buf); X if (t->size == 0) t->size = 18; X return(t); X } END_OF_FILE if test 10940 -ne `wc -c <'fig2dev/read1_3.c'`; then echo shar: \"'fig2dev/read1_3.c'\" unpacked with wrong size! fi # end of 'fig2dev/read1_3.c' fi if test -f 'transfig/Makefile' -a "${1}" != "-c" ; then echo shar: Will not clobber existing file \"'transfig/Makefile'\" else echo shar: Extracting \"'transfig/Makefile'\" \(11099 characters\) sed "s/^X//" >'transfig/Makefile' <<'END_OF_FILE' X# Makefile generated by imake - do not edit! X# $XConsortium: imake.c,v 1.65 91/07/25 17:50:17 rws Exp $ X# X# The cpp used on this machine replaces all newlines and multiple tabs and X# spaces in a macro expansion with a single space. Imake tries to compensate X# for this, but is not always successful. X# X X# ------------------------------------------------------------------------- X# Makefile generated from "Imake.tmpl" and X# $XConsortium: Imake.tmpl,v 1.139 91/09/16 08:52:48 rws Exp $ X# X# Platform-specific parameters may be set in the appropriate .cf X# configuration files. Site-specific parameters should be set in the file X# site.def. Full rebuilds are recommended if any parameters are changed. X# X# If your C preprocessor does not define any unique symbols, you will need X# to set BOOTSTRAPCFLAGS when rebuilding imake (usually when doing X# "make World" the first time). X# X X# ------------------------------------------------------------------------- X# site-specific configuration parameters that need to come before X# the platform-specific parameters - edit site.def to change X X# site: $XConsortium: site.def,v 1.2 91/07/30 20:26:44 rws Exp $ X X# ------------------------------------------------------------------------- X# platform-specific configuration parameters - edit sun.cf to change X X# platform: $XConsortium: sun.cf,v 1.72.1.1 92/03/18 13:13:37 rws Exp $ X X# operating system: SunOS 4.1.2 X X# $XConsortium: sunLib.rules,v 1.7 91/12/20 11:19:47 rws Exp $ X X# ------------------------------------------------------------------------- X# site-specific configuration parameters that go after X# the platform-specific parameters - edit site.def to change X X# site: $XConsortium: site.def,v 1.2 91/07/30 20:26:44 rws Exp $ X X SHELL = /bin/sh X X TOP = ../. X CURRENT_DIR = ./transfig X X AR = ar clq X BOOTSTRAPCFLAGS = X CC = cc X AS = as X X COMPRESS = compress X CPP = /lib/cpp $(STD_CPP_DEFINES) X PREPROCESSCMD = cc -E $(STD_CPP_DEFINES) X INSTALL = install X LD = ld X LINT = lint X LINTLIBFLAG = -C X LINTOPTS = -axz X LN = ln -s X MAKE = make X MV = mv X CP = cp X X RANLIB = ranlib X RANLIBINSTFLAGS = X X RM = rm -f X TROFF = psroff X MSMACROS = -ms X TBL = tbl X EQN = eqn X STD_INCLUDES = X STD_CPP_DEFINES = X STD_DEFINES = X EXTRA_LOAD_FLAGS = X EXTRA_LIBRARIES = X TAGS = ctags X X SHAREDCODEDEF = -DSHAREDCODE X SHLIBDEF = -DSUNSHLIB X X PROTO_DEFINES = X X INSTPGMFLAGS = X X INSTBINFLAGS = -m 0755 X INSTUIDFLAGS = -m 4755 X INSTLIBFLAGS = -m 0644 X INSTINCFLAGS = -m 0444 X INSTMANFLAGS = -m 0444 X INSTDATFLAGS = -m 0444 X INSTKMEMFLAGS = -g kmem -m 2755 X X CDEBUGFLAGS = -O X CCOPTIONS = X X ALLINCLUDES = $(INCLUDES) $(EXTRA_INCLUDES) $(TOP_INCLUDES) $(STD_INCLUDES) X ALLDEFINES = $(ALLINCLUDES) $(STD_DEFINES) $(EXTRA_DEFINES) $(PROTO_DEFINES) $(DEFINES) X CFLAGS = $(CDEBUGFLAGS) $(CCOPTIONS) $(ALLDEFINES) X LINTFLAGS = $(LINTOPTS) -DLINT $(ALLDEFINES) X X LDLIBS = $(SYS_LIBRARIES) $(EXTRA_LIBRARIES) X X LDOPTIONS = $(CDEBUGFLAGS) $(CCOPTIONS) $(LOCAL_LDFLAGS) X X LDCOMBINEFLAGS = -X -r X DEPENDFLAGS = X X MACROFILE = sun.cf X RM_CMD = $(RM) *.CKP *.ln *.BAK *.bak *.o core errs ,* *~ *.a .emacs_* tags TAGS make.log MakeOut X X IMAKE_DEFINES = X X IRULESRC = $(CONFIGDIR) X IMAKE_CMD = $(IMAKE) -DUseInstalled -I$(IRULESRC) $(IMAKE_DEFINES) X X ICONFIGFILES = $(IRULESRC)/Imake.tmpl $(IRULESRC)/Imake.rules \ X $(IRULESRC)/Project.tmpl $(IRULESRC)/site.def \ X $(IRULESRC)/$(MACROFILE) $(EXTRA_ICONFIGFILES) X X# ------------------------------------------------------------------------- X# X Window System Build Parameters X# $XConsortium: Project.tmpl,v 1.138 91/09/10 09:02:12 rws Exp $ X X# ------------------------------------------------------------------------- X# X Window System make variables; this need to be coordinated with rules X X PATHSEP = / X USRLIBDIR = /usr/lib X BINDIR = /usr/bin/X11 X INCROOT = /usr/include X BUILDINCROOT = $(TOP) X BUILDINCDIR = $(BUILDINCROOT)/X11 X BUILDINCTOP = .. X INCDIR = $(INCROOT)/X11 X ADMDIR = /usr/adm X LIBDIR = $(USRLIBDIR)/X11 X CONFIGDIR = $(LIBDIR)/config X LINTLIBDIR = $(USRLIBDIR)/lint X X FONTDIR = $(LIBDIR)/fonts X XINITDIR = $(LIBDIR)/xinit X XDMDIR = $(LIBDIR)/xdm X TWMDIR = $(LIBDIR)/twm X MANPATH = /usr/man X MANSOURCEPATH = $(MANPATH)/man X MANSUFFIX = l X LIBMANSUFFIX = 3 X MANDIR = $(MANSOURCEPATH)$(MANSUFFIX) X LIBMANDIR = $(MANSOURCEPATH)$(LIBMANSUFFIX) X NLSDIR = $(LIBDIR)/nls X PEXAPIDIR = $(LIBDIR)/PEX X XAPPLOADDIR = $(LIBDIR)/app-defaults X FONTCFLAGS = -t X X INSTAPPFLAGS = $(INSTDATFLAGS) X X IMAKE = imake X DEPEND = makedepend X RGB = rgb X X FONTC = bdftopcf X X MKFONTDIR = mkfontdir X MKDIRHIER = /bin/sh $(BINDIR)/mkdirhier X X CONFIGSRC = $(TOP)/config X DOCUTILSRC = $(TOP)/doc/util X CLIENTSRC = $(TOP)/clients X DEMOSRC = $(TOP)/demos X LIBSRC = $(TOP)/lib X FONTSRC = $(TOP)/fonts X INCLUDESRC = $(TOP)/X11 X SERVERSRC = $(TOP)/server X UTILSRC = $(TOP)/util X SCRIPTSRC = $(UTILSRC)/scripts X EXAMPLESRC = $(TOP)/examples X CONTRIBSRC = $(TOP)/../contrib X DOCSRC = $(TOP)/doc X RGBSRC = $(TOP)/rgb X DEPENDSRC = $(UTILSRC)/makedepend X IMAKESRC = $(CONFIGSRC) X XAUTHSRC = $(LIBSRC)/Xau X XLIBSRC = $(LIBSRC)/X X XMUSRC = $(LIBSRC)/Xmu X TOOLKITSRC = $(LIBSRC)/Xt X AWIDGETSRC = $(LIBSRC)/Xaw X OLDXLIBSRC = $(LIBSRC)/oldX X XDMCPLIBSRC = $(LIBSRC)/Xdmcp X BDFTOSNFSRC = $(FONTSRC)/bdftosnf X BDFTOSNFSRC = $(FONTSRC)/clients/bdftosnf X BDFTOPCFSRC = $(FONTSRC)/clients/bdftopcf X MKFONTDIRSRC = $(FONTSRC)/clients/mkfontdir X FSLIBSRC = $(FONTSRC)/lib/fs X FONTSERVERSRC = $(FONTSRC)/server X EXTENSIONSRC = $(TOP)/extensions X XILIBSRC = $(EXTENSIONSRC)/lib/xinput X PHIGSLIBSRC = $(EXTENSIONSRC)/lib/PEX X X# $XConsortium: sunLib.tmpl,v 1.14.1.1 92/03/17 14:58:46 rws Exp $ X XSHLIBLDFLAGS = -assert pure-text XPICFLAGS = -pic X X DEPEXTENSIONLIB = X EXTENSIONLIB = -lXext X X DEPXLIB = $(DEPEXTENSIONLIB) X XLIB = $(EXTENSIONLIB) -lX11 X X DEPXMULIB = $(USRLIBDIR)/libXmu.sa.$(SOXMUREV) X XMULIBONLY = -lXmu X XMULIB = -lXmu X X DEPOLDXLIB = X OLDXLIB = -loldX X X DEPXTOOLLIB = $(USRLIBDIR)/libXt.sa.$(SOXTREV) X XTOOLLIB = -lXt X X DEPXAWLIB = $(USRLIBDIR)/libXaw.sa.$(SOXAWREV) X XAWLIB = -lXaw X X DEPXILIB = X XILIB = -lXi X X SOXLIBREV = 4.10 X SOXTREV = 4.10 X SOXAWREV = 5.0 X SOOLDXREV = 4.10 X SOXMUREV = 4.10 X SOXEXTREV = 4.10 X SOXINPUTREV = 4.10 X X DEPXAUTHLIB = $(USRLIBDIR)/libXau.a X XAUTHLIB = -lXau X DEPXDMCPLIB = $(USRLIBDIR)/libXdmcp.a X XDMCPLIB = -lXdmcp X X DEPPHIGSLIB = $(USRLIBDIR)/libphigs.a X PHIGSLIB = -lphigs X X DEPXBSDLIB = $(USRLIBDIR)/libXbsd.a X XBSDLIB = -lXbsd X X LINTEXTENSIONLIB = $(LINTLIBDIR)/llib-lXext.ln X LINTXLIB = $(LINTLIBDIR)/llib-lX11.ln X LINTXMU = $(LINTLIBDIR)/llib-lXmu.ln X LINTXTOOL = $(LINTLIBDIR)/llib-lXt.ln X LINTXAW = $(LINTLIBDIR)/llib-lXaw.ln X LINTXI = $(LINTLIBDIR)/llib-lXi.ln X LINTPHIGS = $(LINTLIBDIR)/llib-lphigs.ln X X DEPLIBS = $(DEPXAWLIB) $(DEPXMULIB) $(DEPXTOOLLIB) $(DEPXLIB) X X DEPLIBS1 = $(DEPLIBS) X DEPLIBS2 = $(DEPLIBS) X DEPLIBS3 = $(DEPLIBS) X X# ------------------------------------------------------------------------- X# Imake rules for building libraries, programs, scripts, and data files X# rules: $XConsortium: Imake.rules,v 1.123 91/09/16 20:12:16 rws Exp $ X X# ------------------------------------------------------------------------- X# start of Imakefile X X# TransFig : Fig code translation Makefile creation program X# X# Micah Beck X# X XDEPLIBS = XINCLUDES = -I.. X XSRCS = transfig.c txfile.c mkfile.c sys.c XOBJS = transfig.o txfile.o mkfile.o sys.o X X PROGRAM = transfig X Xall:: transfig X Xtransfig: $(OBJS) $(DEPLIBS) X $(RM) $@ X $(CC) -o $@ $(OBJS) $(LDOPTIONS) $(LOCAL_LIBRARIES) $(LDLIBS) $(EXTRA_LOAD_FLAGS) X Xsaber_transfig:: $(SRCS) X # load $(ALLDEFINES) $(SRCS) $(LOCAL_LIBRARIES) $(SYS_LIBRARIES) $(EXTRA_LIBRARIES) X Xosaber_transfig:: $(OBJS) X # load $(ALLDEFINES) $(OBJS) $(LOCAL_LIBRARIES) $(SYS_LIBRARIES) $(EXTRA_LIBRARIES) X Xinstall:: transfig X @if [ -d $(DESTDIR)$(BINDIR) ]; then set +x; \ X else (set -x; $(MKDIRHIER) $(DESTDIR)$(BINDIR)); fi X $(INSTALL) -c $(INSTPGMFLAGS) transfig $(DESTDIR)$(BINDIR) X Xinstall.man:: transfig.man X @if [ -d $(DESTDIR)$(MANDIR) ]; then set +x; \ X else (set -x; $(MKDIRHIER) $(DESTDIR)$(MANDIR)); fi X $(INSTALL) -c $(INSTMANFLAGS) transfig.man $(DESTDIR)$(MANDIR)/transfig.$(MANSUFFIX) X Xdepend:: X $(DEPEND) $(DEPENDFLAGS) -s "# DO NOT DELETE" -- $(ALLDEFINES) -- $(SRCS) X Xlint: X $(LINT) $(LINTFLAGS) $(SRCS) $(LINTLIBS) Xlint1: X $(LINT) $(LINTFLAGS) $(FILE) $(LINTLIBS) X Xclean:: X $(RM) $(PROGRAM) X Xtransfig.man: ../doc/transfig.1 X ln -s ../doc/transfig.1 transfig.man X Xinstall.man:: fig2ps2tex.man X @if [ -d $(DESTDIR)$(MANDIR) ]; then set +x; \ X else (set -x; $(MKDIRHIER) $(DESTDIR)$(MANDIR)); fi X $(INSTALL) -c $(INSTMANFLAGS) fig2ps2tex.man $(DESTDIR)$(MANDIR)/fig2ps2tex.$(MANSUFFIX) X Xinstall.man:: pic2tpic.man X @if [ -d $(DESTDIR)$(MANDIR) ]; then set +x; \ X else (set -x; $(MKDIRHIER) $(DESTDIR)$(MANDIR)); fi X $(INSTALL) -c $(INSTMANFLAGS) pic2tpic.man $(DESTDIR)$(MANDIR)/pic2tpic.$(MANSUFFIX) X Xfig2dev.man: ../doc/fig2dev.1 X ln -s ../doc/fig2dev.1 fig2dev.man X Xfig2ps2tex.man: ../doc/fig2ps2tex.1 X ln -s ../doc/fig2ps2tex.1 fig2ps2tex.man X Xpic2tpic.man: ../doc/pic2tpic.1 X ln -s ../doc/pic2tpic.1 pic2tpic.man X X# ------------------------------------------------------------------------- X# common rules for all Makefiles - do not edit X Xemptyrule:: X Xclean:: X $(RM_CMD) "#"* X XMakefile:: X -@if [ -f Makefile ]; then set -x; \ X $(RM) Makefile.bak; $(MV) Makefile Makefile.bak; \ X else exit 0; fi X $(IMAKE_CMD) -DTOPDIR=$(TOP) -DCURDIR=$(CURRENT_DIR) X Xtags:: X $(TAGS) -w *.[ch] X $(TAGS) -xw *.[ch] > TAGS X Xsaber: X # load $(ALLDEFINES) $(SRCS) X Xosaber: X # load $(ALLDEFINES) $(OBJS) X X# ------------------------------------------------------------------------- X# empty rules for directories that do not have SUBDIRS - do not edit X Xinstall:: X @echo "install in $(CURRENT_DIR) done" X Xinstall.man:: X @echo "install.man in $(CURRENT_DIR) done" X XMakefiles:: X Xincludes:: X X# ------------------------------------------------------------------------- X# dependencies generated by makedepend X END_OF_FILE if test 11099 -ne `wc -c <'transfig/Makefile'`; then echo shar: \"'transfig/Makefile'\" unpacked with wrong size! fi # end of 'transfig/Makefile' fi echo shar: End of archive 3 \(of 7\). cp /dev/null ark3isdone MISSING="" for I in 1 2 3 4 5 6 7 ; do if test ! -f ark${I}isdone ; then MISSING="${MISSING} ${I}" fi done if test "${MISSING}" = "" ; then echo You have unpacked all 7 archives. rm -f ark[1-9]isdone else echo You still need to unpack the following archives: echo " " ${MISSING} fi ## End of shell archive. exit 0