summaryrefslogtreecommitdiff
path: root/contrib/eqn2graph
diff options
context:
space:
mode:
authorwlemb <wlemb>2002-07-17 04:55:45 +0000
committerwlemb <wlemb>2002-07-17 04:55:45 +0000
commit2d126da890e3f8a788fb11113e45deeef4aa7c3a (patch)
treeb657edb579025108ffbee66f6f95cf7f695a90e5 /contrib/eqn2graph
parent6ec8cde0582c0a3d31b79b67cbba93ec0a376a3e (diff)
downloadgroff-2d126da890e3f8a788fb11113e45deeef4aa7c3a.tar.gz
* contrib/pic2graph/pic2graph.*: Use convert(1).
* contrib/eqn2graph/eqn2graph.*: Minor fixes. * tmac/groff_trace.man: New file. * tmac/Makefile.sub: Updated. * NEWS: Updated. * src/roff/groff/groff.man: Add some cross references. * src/roff/troff/input.cc (substring_request): Add warnings for string indices out of range. * font/devdvi/generate/ec.map: Fix typo (`(l' -> `/l'). * font/devdvi/*EC: Regenerated. * man/groff_char.man: Updated and extended. * src/roff/troff/input.cc (length_macro): Renamed to... (length_request): This. Move call of `tok.next()' to the very end, otherwise the register value hasn't been updated yet. (init_input_requests): Updated. * src/roff/troff/input.cc (substring_macro): Renamed to... (substring_request): This. (init_input_requests): Updated. * src/roff/troff/request.h: Updated. * src/roff/grog/grog.sh: Fix typo. * win32-diffs: Updated. Handle `papersize' keyword properly in DESC. * src/libs/libgroff/font.cc (font::scan_papersize): Fix argument type. Updated all callers. * src/libs/libgroff/paper.cc: Add four more paper formats used by grolj4. * src/include/paper.h: Updated. * src/devices/grolbp/lbp.cc: Remove unnecessary semicolons. Other minor C syntax fixes. (papersize, paperlength, paperwidth): Renamed to `user_*'. (lbp_printer): Add `papersize', `paperlength', and `paperwidth' members. (lbp_printer::lbp_printer): Pass three arguments. Set paper dimensions properly. (make_printer, main): Updated. (handle_unknown_desc_command): Fix error messages. (main): Handle papersize keyword in DESC properly. * src/devices/grolj4/lj4.cc (paper_size): Renamed to `user_paper_size'. (lbp_printer::lbp_printer): Pass an argument. Set paper_size properly. (handle_unknown_desc_command): Removed. (make_printer, main): Updated. * src/devices/grolj4/grolj4.man: Minor documentation fix. * man/groff_font.man, NEWS: Updated.
Diffstat (limited to 'contrib/eqn2graph')
-rw-r--r--contrib/eqn2graph/eqn2graph.sh27
1 files changed, 19 insertions, 8 deletions
diff --git a/contrib/eqn2graph/eqn2graph.sh b/contrib/eqn2graph/eqn2graph.sh
index 9ecea743..e314dc91 100644
--- a/contrib/eqn2graph/eqn2graph.sh
+++ b/contrib/eqn2graph/eqn2graph.sh
@@ -9,12 +9,13 @@
# Take an eqn equation on stdin, emit cropped bitmap on stdout.
# The pic markup should *not* be wrapped in .EQ/.EN, this script will do that.
# A -U option on the command line enables gpic/groff "unsafe" mode.
-# All other options are passed to convert (or whichever back end is selected
-# by the format option). The default format is PNG.
+# A -format FOO option changes the image output format to any format
+# supported by convert(1). All other options are passed to convert(1).
+# The default format is PNG.
#
# This is separate from pic2graph because pic processing has some weird
# clipping effect on the output, mangling equations that are very wide
-# or deep. Besides, this rool can supply its own delimiters.
+# or deep. Besides, this tool can supply its own delimiters.
#
# Requires the groff suite and the ImageMagick tools. Both are open source.
@@ -31,7 +32,7 @@
#
# Thus, we pass -U to groff(1), and everything else to convert(1).
#
-# $Id: eqn2graph.sh,v 1.1 2002/07/07 22:14:56 wlemb Exp $
+# $Id: eqn2graph.sh,v 1.2 2002/07/17 04:55:46 wlemb Exp $
#
groff_opts=""
convert_opts=""
@@ -40,11 +41,21 @@ format="png"
while [ "$1" ]
do
case $1 in
- -unsafe) groff_opts="-U";;
- -format) format=$2; shift;;
- *) convert_opts="$convert_opts $1" ;;
+ -unsafe)
+ groff_opts="-U";;
+ -format)
+ format=$2
+ shift;;
+ -v | --version)
+ echo "GNU eqn2graph (groff) version @VERSION@"
+ exit 0;;
+ --help)
+ echo "usage: eqn2graph [ option ...] < in > out"
+ exit 0;;
+ *)
+ convert_opts="$convert_opts $1";;
esac
- shift;
+ shift
done
# Here goes: