+15 Sep 2004 Aron Griffis <agriffis@gentoo.org>
+ * fix the wrapping to fit in 80 columns properly. It was
+ previously possible to get lines with 81 chars. Thanks to
+ ciaranm for reporting.
+
29 Mar 2004 Aron Griffis <agriffis@gentoo.org>
* fix bug 46111 by testing for /<root@/ instead of / root@/
setlocale(&POSIX::LC_ALL, "C");
use Text::Wrap;
-$Text::Wrap::columns = 79;
+$Text::Wrap::columns = 77;
$Text::Wrap::unexpand = 0;
# Global variables
die "Empty entry; aborting\n" unless $input =~ /\S/;
# If there are any long lines, then wrap the input at $columns chars
-# (leaving 2 chars on each end after adding indentation below).
+# (leaving 2 chars on left, one char on right, after adding indentation below).
$input =~ s/^\s*(.*?)\s*\z/$1/s; # trim whitespace
$input = Text::Wrap::fill('', '', $input) if ($input =~ /^.{80}/m);
$input =~ s/^/ /gm; # add indentation