diff options
author | Norbert Preining <norbert@preining.info> | 2019-09-02 13:46:59 +0900 |
---|---|---|
committer | Norbert Preining <norbert@preining.info> | 2019-09-02 13:46:59 +0900 |
commit | e0c6872cf40896c7be36b11dcc744620f10adf1d (patch) | |
tree | 60335e10d2f4354b0674ec22d7b53f0f8abee672 /macros/plain/contrib/pdcmac/fig2epsf |
Initial commit
Diffstat (limited to 'macros/plain/contrib/pdcmac/fig2epsf')
-rw-r--r-- | macros/plain/contrib/pdcmac/fig2epsf | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/macros/plain/contrib/pdcmac/fig2epsf b/macros/plain/contrib/pdcmac/fig2epsf new file mode 100644 index 0000000000..18b7ab5298 --- /dev/null +++ b/macros/plain/contrib/pdcmac/fig2epsf @@ -0,0 +1,36 @@ +#! /bin/sh
+
+# Convert Fig files to conformant EPSF-3.0 files
+# Fig's PostScript translation creates EPSF files that cause
+# many laser printers to abort in mid-document.
+# This script attempts to remedy this.
+
+version="1.0 Time-stamp: <pdc 1995-03-24>"
+
+# Usage fig2epsf [ -m MAG ] [ -f FONT ] [ -s FSIZE ] [
+
+case $1 in
+ -V|--version)
+ echo 'This is fig2epsf $version, using fig2dev from'
+ fig2dev -V
+ exit 0
+esac
+
+fig2dev -Lps $* | sed '
+ s/^%!$/%!PS-Adobe-3.0 EPSF-3.0/
+ s/^%!PS-Adobe-2.0 EPSF-2.0/%!PS-Adobe-3.0 EPSF-3.0/
+ s/%%Pages: 0/%%Pages: 1/
+ /\/\$F2psDict/d
+ /\$F2psDict begin/d
+ / end/d
+ /\/\$F2psBegin/d
+ /\/\$F2psEnd/d
+ /\$F2psBegin/d
+ /\/col-1/d
+ s/col-1//g
+ s,\$F2psDict /mtrx matrix put,/mtrx matrix def,
+ s/\$F2psEnd/showpage/
+ /%%EndProlog/a\
+\
+%%Page: 1 1
+'
|