From: Peter Graves <peter@ar...> - 2002-06-23 18:16:34
I've rewritten MessageBuffer.quoteBody(), which is responsible for
formatting the quoted text of the mail message being replied to for
insertion into the reply.
The new code makes no attempt to wrap lines beginning with whitespace
or '>', to minimize the disruption of text that has already been
formatted by the sender.
In general, the wrap column that's in force in SendMail mode (which is
the value of the property SendMailMode.wrapCol, if it's set, or the
global default, if it's not) is used as the wrap column for the quoted
text, but text that fits in 78 columns (a hard-coded value) is passed
The theory behind this is that "normal" lines are either about the
right length or else they're very long. We want to wrap them if
they're very long, but if they are close to the right length, it's
probably best to leave them alone, since it's possible for the
wrapping code to make mistakes. The choice of 78 is arbitrary (with
the prepended "> " it's the width of a standard console window) and
might be subject to further tuning.
The result of all this is that the quoted text may well be wider, in
places, than it should be, strictly speaking, but it will probably
look better. And appearance does count... ;)
The latest code is here:
http://armedbear.org/j-jar.zip (just j.jar)