diff options
-rw-r--r-- | doc/HISTORY | 6 | ||||
-rwxr-xr-x | editor/pnmmargin | 14 |
2 files changed, 16 insertions, 4 deletions
diff --git a/doc/HISTORY b/doc/HISTORY index dae35d32..c4d5ae3d 100644 --- a/doc/HISTORY +++ b/doc/HISTORY @@ -6,6 +6,12 @@ CHANGE HISTORY not yet BJH Release 10.40.00 + pnmmargin: add -plain option. Thanks + Prophet of the Way <afu@wta.att.ne.jp>. + + pnmmargin: recognize invalid options better. Thanks + Prophet of the Way <afu@wta.att.ne.jp>. + pnmtopng: Sort palette properly when alpha maxval != 255. pnmtopng: Fix array bound violation with = 256 colors and -alpha. diff --git a/editor/pnmmargin b/editor/pnmmargin index 31420f99..b4c87bb7 100755 --- a/editor/pnmmargin +++ b/editor/pnmmargin @@ -23,19 +23,24 @@ tmp3=$tempdir/pnmm3 tmp4=$tempdir/pnmm4 color="-gofigure" +plainopt="" # Parse args. while true ; do case "$1" in - -w* ) + -p|-pl|-pla|-plai|-plain ) + plainopt="-plain" + shift + ;; + -w|-wh|-whi|-whit|-white ) color="-white" shift ;; - -b* ) + -b|-bl|-bla|-blac|-black ) color="-black" shift ;; - -c* ) + -c|-co|-col|-colo|-color ) shift if [ ! ${1-""} ] ; then echo "usage: $0 [-white|-black|-color <colorspec>] <size> [pnmfile]" 1>&2 @@ -85,4 +90,5 @@ pamflip -rotate90 $tmp2 > $tmp3 # Cat things together. pnmcat -lr $tmp2 $tmp1 $tmp2 > $tmp4 -pnmcat -tb $tmp3 $tmp4 $tmp3 +pnmcat -tb $plainopt $tmp3 $tmp4 $tmp3 + |