Subject: Re: bug#78561: [PATCH] Add semantic linefeed support for paragraph filling

From: Roi Martin <[email-masked]>
Date: Sat, 21 Jun 2025 21:57:42 +0200

Eli Zaretskii <[email-masked]> writes:

> Do you have sentence-end-double-space set to nil?  If yes, this is a
> feature.  If no, that's indeed a bug, since semantic linefeed should
> not consider a single space after a period to be the end of a sentence
> in that case.
>
> Roi, could you take a look, please?

This is indeed related to the value of `sentence-end-double-space'.

When `sentence-end-double-space' is non-nil, `fill-paragraph-semlf'
produces:
  
  Hi there Chris! I see you've got your M.D. now so I suppose I should
  call you Dr. Yoo. I hear you're also a newly appointed U.S. Rep., what
  is that like? Good I hope.

When `sentence-end-double-space' is nil, `fill-paragraph-semlf'
produces:
  
  Hi there Chris!
  I see you've got your M.D.
  now so I suppose I should call you Dr.
  Yoo.
  I hear you're also a newly appointed U.S.
  Rep., what is that like?
  Good I hope.

Actually, there is a test for this.  See
`fill-test-fill-paragraph-semlf-sentence-end-double-space'.

`fill-paragraph-semlf' uses `forward-sentence' internally to move
between sentences.  So, IMHO dealing with more complex ways of finding
sentences is out of the scope of the semantic linefeed filling feature.

        Roi