GNU bug report logs - #72870
[PATCH] Flow fill texts after the last hard newline

Previous Next

Package: emacs;

Reported by: Pengji Zhang <me <at> pengjiz.com>

Date: Thu, 29 Aug 2024 10:59:01 UTC

Severity: normal

Tags: patch

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Pengji Zhang <me <at> pengjiz.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 72870 <at> debbugs.gnu.org
Subject: bug#72870: [PATCH] Flow fill texts after the last hard newline
Date: Mon, 09 Sep 2024 12:04:02 +0800
Pengji Zhang <me <at> pengjiz.com> writes:

> Eli Zaretskii <eliz <at> gnu.org> writes: 
> 
>> AFAICT, this function exists for the special case of decoding 
>> email messages. Can email messages have flowed-encoded text 
>> without a hard newline at the end?  
> 
> I think you meant "encoding"? Anyway, if I understand it 
> correctly, an email message should always end with a newline, 
> but  it is not necessarily a hard newline. For example, 
> 'message.el'  inserts a normal newline: 
> 
>   https://git.savannah.gnu.org/cgit/emacs.git/tree/lisp/gnus/message.el#n4944 

I just realized this insertion of newline happens after encoding, 
so this is irrelevant here. Sorry.

It seems that during encoding, no such a newline is added at all. 
To reproduce:

 - Run 'emacs -Q'
 - C-x m C-c C-b
 - M-x use-hard-newlines RET n
 - C-x f 10 RET
 - Eval: (dotimes (i 10) (insert "word "))
 - RET RET
 - Eval: (dotimes (i 10) (insert "word "))
 - M-q
 - C-u M-x mml-preview RET

In the preview buffer, the first paragraph is filled but the 
second is not.




This bug report was last modified 225 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.