[MlMt] Plain text line wrapping

Randall Gellens mailmate at randy.pensive.org
Wed Jun 26 16:30:47 EDT 2024


On 26 Jun 2024, at 8:54, Bill Cole wrote:

> On 2024-06-26 at 05:23:12 UTC-0400 (Wed, 26 Jun 2024 11:23:12 +0200)
> Eelco Chaudron <mailmate at lists.freron.com>
> is rumored to have said:
>
>> Yes, but that is the behavior I do not want. I want mm to auto wrap 
>> when typing. This is useful when replying to patches we’re auto 
>> formatting might be messing stuff up.
>
> MM (and anything that supports format=flowed properly) respects 
> explicit line breaks and does not re-wrap text with fixed line breaks 
> such as code patches when composing replies.

That's correct F=F behavior.

> It also will NOT "auto-wrap" by forcibly inserting  line breaks to 
> enforce a maximum line length, as that would harm intentional 
> formatting for text such as code.

Correct F=F behavior is to insert a "soft" line break so lines intended 
for refolding are no more than 78 characters. By inserting "soft" line 
breaks within a plain text F=F body (or body part), the text is more 
easily handled by non-F=F clients.

Within a plain text F=F body (or body part), there is a distinction 
between lines that have a "soft" line break for backwards compatibility 
and thus suitable for reflowing by a F=F-aware displaying client, and 
lines that have a "hard" line break (e.g., because they're code or 
poetry or an ASCII table or whatever). (A soft line break is a space 
CRLF sequence.)

F=F also standardizes marking lines as quoted, so they can be correctly 
reflowed by a F=F-aware displaying client to fit the window size.


> Note that some MUAs do not respect explicit line breaks and may delete 
> them to reflow text, notably MS Outlook. Some MUAs also do not 
> understand how to present "format=flowed" plaintext, leaving sections 
> that should be soft-wrapped by the MUA to run right off the edge of a 
> window.
>
>> So it’s more an editor/composer feature what I need.

Since F=F requires only that soft-wrapped lines not exceed 78 
characters, MailMate could have a preference for the maximum 
soft-wrapped line length, default 78, maximum value 78. Users who care 
could set this to a lower value to cause shorter soft-wrapped lines.

If MailMate is generating F=F with soft-wrapped lines exceeding 78 
characters, I'd say that's a bug.

--Randall


More information about the mailmate mailing list