home *** CD-ROM | disk | FTP | other *** search
/ Garbo / Garbo.cdr / mac / source / adobeenc.zoo / encrypt.shar / transform < prev    next >
Encoding:
Text File  |  1990-10-27  |  537 b   |  29 lines

  1. #!/bin/sh
  2. #
  3. # transform -- transform an Adobe Type 1 font file
  4. #   encrypted with eexec and CharStrings into raw PostScript
  5. #
  6.  
  7. PROGRAM=`basename $0`
  8. TMP1=/tmp/$$.tr1
  9. TMP2=/tmp/$$.tr2
  10. TMP3=/tmp/$$.tr3
  11. TMP4=/tmp/$$.tr4
  12. TMP5=/tmp/$$.tr5
  13.  
  14. trap 'rm -f /tmp/$$.tr?; exit 0' 0 1 2 15
  15.  
  16. case $# in
  17. 2) ;;
  18. *) echo "Usage: $PROGRAM \"Adobe Type 1 font file\" \"output file\""
  19.    exit 1;;
  20. esac
  21.  
  22. eexec $1 > $TMP1
  23. chars $TMP1 $TMP2
  24. sed -e '/definefont/,$d' $TMP2 > $TMP3
  25. cat header.ps $TMP3 trailer.ps > $TMP4
  26. DPS > $2 <<end-of-here
  27. #$TMP4
  28. end-of-here
  29.