emacs-devel
[Top][All Lists]
Advanced

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

Re: query-replace doesn't match spaces with soft newlines


From: Juri Linkov
Subject: Re: query-replace doesn't match spaces with soft newlines
Date: Tue, 12 Feb 2008 02:16:12 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux)

>> Perhaps I missed a discussion about the design of longlines-mode,
>> so I don't understand why longlines-mode doesn't put a `display'
>> property with a newline on whitespace to display it as soft newlines.
>> This would avoid many such problems.
>
> Because doing that makes many important emacs commands work incorrectly
> (from the user's viewpoint) -- e.g., C-e will move to the end of the
> paragraph...

Ok, I see now.  Many commands are expected to work on the visual
representation, so only a few commands that incorrectly treat inserted
newlines should be fixed.  I see no problem in matching additional
newlines in `query-replace' and the regexp search, but I don't see
how to distinguish soft newlines inserted by longlines-mode and hard
newlines with the `hard' property using the regexp search, i.e. how
(re-search-forward "[ \t\n]") could find soft newlines and skip
hard newlines?

-- 
Juri Linkov
http://www.jurta.org/emacs/




reply via email to

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