summaryrefslogtreecommitdiff
path: root/dviware/quicspool/src/qtroff.backup
diff options
context:
space:
mode:
Diffstat (limited to 'dviware/quicspool/src/qtroff.backup')
-rw-r--r--dviware/quicspool/src/qtroff.backup60
1 files changed, 60 insertions, 0 deletions
diff --git a/dviware/quicspool/src/qtroff.backup b/dviware/quicspool/src/qtroff.backup
new file mode 100644
index 0000000000..4d963ca231
--- /dev/null
+++ b/dviware/quicspool/src/qtroff.backup
@@ -0,0 +1,60 @@
+#! /bin/sh
+# $Header: qtroff.backup,v 1.1 88/01/15 13:05:19 simpson Rel $
+# $Log: qtroff.backup,v $
+#Revision 1.1 88/01/15 13:05:19 simpson
+#initial release
+#
+#Revision 0.1 87/12/11 18:31:17 simpson
+#beta test
+#
+# Unfortunately it is necessary to use this script for otroff since the
+# troff macro file mount.nr must be read by otroff or the width tables in
+# --OFONT-- will not be read. Two -m (macro) options cannot be given
+# to otroff. If you could, we would name the macro file tmac.ount and use
+# the command
+# otroff -t -mount $* | lpr -t
+# We would still have to resolve the flags to otroff and lpr though.
+troffflags='-rv1 -t -F--OFONT--/ftXX'
+lprflags='-t'
+while [ $# -gt 0 ];do
+ case $1 in
+# Begin of otroff flags
+ -o* | -n* | -m* | -i | -q | -f | -b | -a | -p* | -F* | -z)
+ troffflags="$troffflags $1"
+ shift
+ ;;
+# Begin of lpr flags
+ -P* | -\#* | -w* | -l | -t | -d | -g | -v | -c | -r | -h | -s | -L)
+ lprflags="$lprflags $1"
+ shift
+ ;;
+ -C | -J | -1 | -2 | -3 | -4)
+ lprflags="$lprflags $1 $2"
+ shift; shift
+ ;;
+# Troff extension flags
+ -R*)
+ troffflags="$troffflags `echo $1|sed s/-R/-r/`"
+ shift
+ ;;
+# Lpr extension flags
+ -M)
+ lprflags="$lprflags -m"
+ shift
+ ;;
+# Any remaining flags go to troff
+ -*)
+ troffflags="$troffflags $1"
+ shift
+ ;;
+ *)
+ break
+ ;;
+ esac
+done
+if [ $# -eq 0 ]; then
+ readstdin=-i
+else
+ readstdin=
+fi
+otroff $readstdin $troffflags --FILTER--/mount.nr $* | glpr $lprflags