[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: require-hard-newlines to use newline
From: |
Richard Stallman |
Subject: |
Re: require-hard-newlines to use newline |
Date: |
Sat, 12 Mar 2005 17:16:03 -0500 |
> If we agree that those hooks are the proper approach, and you can
> write the proper doc for them, this is a trivial change, so I don't
> see why we have to wait.
Okay then. How about this patch?
It only does a part of the job. It handles kill, but not registers,
etc. I think it is implemented at the wrong level.
Stefan wrote:
I think it's usually important to keep the property that killing doesn't
modify the buffer's text (when used in copy-as-kill), so rather than having
before-kill-functions modify the buffer's text just before it's put in the
kill-ring, it would be more convenient to make it return the string,
i.e. use it as a replacement for buffer-substring.
That is true, too.
Another possibility is not to use a hook at all, e.g.:
(defvar kill-filters nil
"List of functions for converting a string before it is killed.
Each function should accept a single argument, a string, and
return a string.
That is more the right idea, for the part that reads from
the buffer. But it is not correct to associate this with
killing. Think of it as a variant of buffer-substring.
But that makes it difficult to process the string in a way that depends on
its context.
Maybe so, but is it necessary to do that?
- Re: require-hard-newlines to use newline, (continued)
- Re: require-hard-newlines to use newline, Chong Yidong, 2005/03/11
- Re: require-hard-newlines to use newline, Stefan Monnier, 2005/03/11
- Re: require-hard-newlines to use newline, Chong Yidong, 2005/03/11
- Re: require-hard-newlines to use newline, Stefan Monnier, 2005/03/11
- Re: require-hard-newlines to use newline, Chong Yidong, 2005/03/11
- Re: require-hard-newlines to use newline, Kim F. Storm, 2005/03/11
- Re: require-hard-newlines to use newline, Chong Yidong, 2005/03/11
- Re: require-hard-newlines to use newline,
Richard Stallman <=
- Re: require-hard-newlines to use newline, Stefan Monnier, 2005/03/12
- Re: require-hard-newlines to use newline, Richard Stallman, 2005/03/13
- Re: require-hard-newlines to use newline, Chong Yidong, 2005/03/13
- Re: require-hard-newlines to use newline, Richard Stallman, 2005/03/13
- Re: require-hard-newlines to use newline, Chong Yidong, 2005/03/13
- Re: require-hard-newlines to use newline, Richard Stallman, 2005/03/15
- Re: require-hard-newlines to use newline, Richard Stallman, 2005/03/12
- Re: require-hard-newlines to use newline, Richard Stallman, 2005/03/04
- Re: require-hard-newlines to use newline, Chong Yidong, 2005/03/04
- Re: require-hard-newlines to use newline, Richard Stallman, 2005/03/05