On 05Sep2022 01:52, Kurt Hackenberg <k...@panix.com> wrote:
On Mon, Sep 05, 2022 at 08:36:54AM +1000, Cameron Simpson wrote:
But not space-stuffing, right?
Aye. I avoid lines commencing with a ">" just because they look quoted
to my eye anyway, so that aside "live" space stuffing in authoring is
something I'd find distracting.
Agreed, I wouldn't want space-stuffing maintained on the fly, while
editing. It could be done at the end, when handing the message back to
Mutt.
It seems a little conceptually cleaner to have the editor do the whole
job, rather than divide it between the editor and Mutt. But another
complication is that you can edit a message more than once...
I think space stuffing is effectively an escape mechanism, like quoted
printable; not something you see at authoring time. The RFC even says
"(Note that space-stuffing is conceptually similar to dot-stuffing as
specified in [SMTP].)", which is again a transport level escaping.
So we need the overt trailing-space stuff because that's an indicator of
end-of-paragraph in f=f, but not the space stuffing, because that is
only needed to transport the text.
[...]
The second one works differently. It's a "major mode"; it has commands
to convert both ways between format=flowed and one-line paragraphs,
while you edit. The idea is to type with each paragraph being a single
long line, and then "encode" that as format=flowed when you're done.
That doesn't mess with existing mechanisms, and doesn't take much code.
Emacs has something called "visual line mode" to make those long lines
not ugly.
Ah, I was wondering about that, because I find the one-line-paragraph
thing wearing with quite long lines.
That second one is attached, for anyone who's interested (Cameron, I
suppose you probably don't use Emacs).
Indeed not. I took the Other Path long ago.
Don't encode/decode the message header section; that could
possibly break things. It's best to tell Mutt
set edit_headers = no
to avoid that possibility.
I like to edit headers, so my vim-flavoured mode trims all trailing
spaces from the header lines at startup:
1,/^$/s/ *$//
That way they're "hard newlines" from the flowed point of view, and
survive.
Cheers,
Cameron Simpson <c...@cskk.id.au>