emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: longlines mode and kill-line: missing space between boundary words


From: martin rudalics
Subject: Re: longlines mode and kill-line: missing space between boundary words
Date: Wed, 05 Dec 2007 23:58:55 +0100
User-agent: Mozilla Thunderbird 1.0 (Windows/20041206)

> In longlines mode when I press C-k (i.e. a kill-line command) in a
> long paragraph with soft linebreaks and then press C-y to yank the
> killed line somewhere, the spaces between the words on soft-broken
> lines' boundaries disapear.
>
...
>
> I guess after kill-line the longline mode automatically compresses the
> soft-linebreak at the end of the line (because the space is
> temporarily turned into a soft linebreak) and the information about
> the space does not get into the kill ring.

Yes.  `kill-line' kills the line without the newline and longlines mode
removes the newline character after that.

> The consistent behaviour would be either to add the missing space to
> the kill ring or (it that is impossible or too hard) to kill the whole
> paragraph at once (since it in fact is a single line). The first
> behaviour clearly looks better to me.

I'm afraid that it's hardly possible to DTRT here.  Adding the space is
not quite correct since `kill-line' doesn't kill the newline character
which substitutes the space.  Note that you get a similar bug when you
kill the line + the newline character.  Reinserting the killed stretch
will get you a hard newline instead of the soft one.

Killing everything up to the next hard newline appears conceptually
right.  It would clash, however, with the current concept that a line
for `kill-line' is pretty much a line as it appears on the screen.
Moreover, `kill-line' would have to become aware of longlines' way of
distinguishing soft and hard newlines.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]