home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / misc / volume17 / psnup / patch01 / psnup.patch1
Encoding:
Text File  |  1991-03-09  |  5.2 KB  |  189 lines

  1. *** orig/README    Fri Feb 22 11:03:09 1991
  2. --- README    Fri Feb 22 11:32:19 1991
  3. ***************
  4. *** 1,3 ****
  5. --- 1,38 ----
  6. +             PSNUP README Patch 1
  7. +             Chris Lewis
  8. + This release is a combination of two things: a generalized n-up processor
  9. + for postscript files, plus a shell wrapper script and manual page.
  10. + Ned Batchelder wrote the postscript n-up handling and postscript
  11. + compressor program, and I wrote the shell wrapper script and manual page.
  12. + I include the original README from Ned Batchelder below.  Note, however,
  13. + that the psnup shell script performs the parameter substitution that Ned
  14. + refers to.  Therefore, you don't have to do anything to the nup.* stuff.
  15. + Patch 1 note: I'm more than a little embarrassed about the difficulties
  16. + in the shell script and manual page.  That's what comes of not testing
  17. + the final version.  In particular, the manual page did not make it clear
  18. + that the origin for "-s" is 0 not 1, and the default should be 0 not 1,
  19. + and that the -r & -R implementation was reversed.  Hence the fixes to
  20. + psnup.sh and psnup.1.  As well, there was a bug in psc.c in that the
  21. + return from getchar() was defined as a char, which can cause infinite
  22. + loops on some machines.
  23. + Other changes include this little note in the README (because some people
  24. + were editting nup.* directly, which they don't need to) and a removal
  25. + of the "%!" from nup.post.ps.
  26. + Psroff (CAT & ditroff -2- HPLJ/ditroff/Postscript) has been
  27. + modified to utilize the nup.epi and nup.pro files.  So, you'll want
  28. + to keep this if you intend to use psroff.  Psroff 3.0 will be released
  29. + soon.
  30. + And finally, like all n-up programs, it is possible for it to be fooled.
  31. + Nup does what it does by redefining a few operators, such as initgraphics.
  32. + Be aware that some applications (tpscript seems to be one of them) will
  33. + foul up nup's definitions, and the results will not be what you intended.
  34. + -------------------------------------------
  35.       Nup is designed to be used as a wrap around any PostScript file.
  36.   Simply prepend nup.pre.ps, and append nup.post.ps, and it should work. There
  37.   are three tokens in nup.pre.ps which need to be changed before sending it to
  38. *** orig/nup.post.ps    Fri Feb 22 11:03:13 1991
  39. --- nup.post.ps    Fri Feb 22 11:07:06 1991
  40. ***************
  41. *** 1,4 ****
  42. ! %! nup.post.ps -- Postlude for n-up printing. $Revision: 4.2 $
  43.   %
  44.   % Ned Batchelder, University of Pennsylvania
  45.   % ned@UPenn.CSnet
  46. --- 1,4 ----
  47. ! % nup.post.ps -- Postlude for n-up printing. $Revision: 4.2 $
  48.   %
  49.   % Ned Batchelder, University of Pennsylvania
  50.   % ned@UPenn.CSnet
  51. *** orig/psc.c    Fri Feb 22 11:03:18 1991
  52. --- psc.c    Sat Feb 16 22:49:00 1991
  53. ***************
  54. *** 33,39 ****
  55.       int    inhex = 0;    /* Are we in a hex string? */
  56.       int    column = 0;    /* Counts output columns to keep lines short */
  57.       int    keepch = 0;    /* For breaking strings */
  58. !     char    c;        /* The current character */
  59.   
  60.   # define put(c)        {putchar(c); column++;}
  61.   
  62. --- 33,39 ----
  63.       int    inhex = 0;    /* Are we in a hex string? */
  64.       int    column = 0;    /* Counts output columns to keep lines short */
  65.       int    keepch = 0;    /* For breaking strings */
  66. !     int    c;        /* The current character */
  67.   
  68.   # define put(c)        {putchar(c); column++;}
  69.   
  70. *** orig/psnup.1    Fri Feb 22 11:03:20 1991
  71. --- psnup.1    Mon Feb 18 21:38:35 1991
  72. ***************
  73. *** 42,53 ****
  74.   The
  75.   .BI -s n
  76.   option indicates which spot the first page of output occurs in.
  77.   .P
  78.   The defaults are:
  79.   .BR -p2 ,
  80. ! .BR -r ,
  81.   and
  82. ! .BR -s1 ,
  83.   .P
  84.   .B Psnup
  85.   tries very hard to retain a trailing control-D if the file has
  86. --- 42,54 ----
  87.   The
  88.   .BI -s n
  89.   option indicates which spot the first page of output occurs in.
  90. + The first spot on the page is 0.
  91.   .P
  92.   The defaults are:
  93.   .BR -p2 ,
  94. ! .BR -R ,
  95.   and
  96. ! .BR -s0 .
  97.   .P
  98.   .B Psnup
  99.   tries very hard to retain a trailing control-D if the file has
  100. *** orig/psnup.sh    Fri Feb 22 11:03:21 1991
  101. --- psnup.sh    Fri Feb 22 11:32:50 1991
  102. ***************
  103. *** 9,18 ****
  104.   rm -f /tmp/?$$
  105.   
  106.   pages=2
  107. ! #    Default is reversed for use with psroff with psxlate in the
  108. ! #    pipeline to reverse pages.
  109. ! reverse=true
  110. ! start=1
  111.   
  112.   for i
  113.   do
  114. --- 9,17 ----
  115.   rm -f /tmp/?$$
  116.   
  117.   pages=2
  118. ! #    Default is nonreversed for use with forward printing printers.
  119. ! reverse=false
  120. ! start=0
  121.   
  122.   for i
  123.   do
  124. ***************
  125. *** 19,29 ****
  126.       case $i in
  127.       -p2 | -p4 | -p8 | -p16)
  128.           pages=`echo $i | sed -e 's/^..//'`
  129. -         if [ -z "$pages" -o -n "`echo $pages | sed -e 's/[0-9]*//'`" ]
  130. -         then
  131. -         echo "$0: Non-numeric pages per sheet option $i" >&2
  132. -         exit 1
  133. -         fi
  134.           ;;
  135.       -p*)
  136.           echo "$0: -p option ($i) must be 2, 4, 8 or 16" >&2
  137. --- 18,23 ----
  138. ***************
  139. *** 30,39 ****
  140.           exit 1
  141.           ;;
  142.       -r)
  143. !         reverse=false
  144.           ;;
  145.       -R)
  146. !         reverse=true
  147.           ;;
  148.       -s*)
  149.           start=`echo $i | sed -e 's/^..//'`
  150. --- 24,33 ----
  151.           exit 1
  152.           ;;
  153.       -r)
  154. !         reverse=true
  155.           ;;
  156.       -R)
  157. !         reverse=false
  158.           ;;
  159.       -s*)
  160.           start=`echo $i | sed -e 's/^..//'`
  161. ***************
  162. *** 54,62 ****
  163.       esac
  164.       shift
  165.   done
  166. ! if [ $start -gt $pages ]
  167.   then
  168. !     echo "$0: start option (-s$start) must be <= pages/sheet (-p$pages)" \
  169.       >&2
  170.       exit 1
  171.   fi
  172. --- 48,56 ----
  173.       esac
  174.       shift
  175.   done
  176. ! if [ $start -ge $pages ]
  177.   then
  178. !     echo "$0: start option (-s$start) must be < pages/sheet (-p$pages)" \
  179.       >&2
  180.       exit 1
  181.   fi
  182.  
  183.