Subject: Re: bug#74785: 27.1; Fill-paragraph in RST mode does not respect line blocks

From: Stefan Merten <[email-masked]>
Date: Mon, 16 Dec 2024 23:05:11 +0100

Hi Eli!

2 days ago Eli Zaretskii wrote:
>> Date: Wed, 11 Dec 2024 10:37:01 +0000
>> From: Richard Brooksby <[email-masked]>
>> 
>> 
>> 
>> Fill-paragraph (M-Q) in a reStructuredText document that is formatted
>> using "Line Blocks"
>> <https://docutils.sourceforge.io/docs/ref/rst/restructuredtext.html#line-blocks>
>> such as:
>> 
>>    | In Xanadu did Kubla Khan
>>    | A stately pleasure-dome decree:
>>    | Where Alph, the sacred river, ran
>>    | Through caverns measureless to man
>>    | Down to a sunless sea.
>> 
>> results in this:
>> 
>>    | In Xanadu did Kubla Khan | A stately pleasure-dome decree: | Where
>>    Alph, the sacred river, ran | Through caverns measureless to man |
>>    Down to a sunless sea.
>> 
>> but in this case it should leave the line breaks intact.  The code
>> should probably treat the vertical bars something like list bullets,
>> since continuation lines are possible, e.g.
>> 
>>    | This is the all the first line
>>      of output even though it's two lines
>>      of input.
>>    | This is second line in the output.
>>    | And this is the third.
>> 
>> (I searched <https://debbugs.gnu.org/cgi/pkgreport.cgi?package=emacs>
>> for a similar report.  Apologies if I was not thorough enough.)
> 
> Stefan and Stefan, any ideas or suggestions?

Richard is right: Filling should consider line blocks. OTOH line
blocks are really a rarely used feature I guess, so it doesn't hurt
much.

I'll look deeper into the code. But don't hold your breath ;-) .

						Regards

						Stefan