emacs-pretest-bug
[Top][All Lists]
Advanced

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

Re: Undo discard prompt


From: Kim F. Storm
Subject: Re: Undo discard prompt
Date: Wed, 26 Jan 2005 11:40:04 +0100
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/21.3.50 (gnu/linux)

Richard Stallman <address@hidden> writes:

>       Now I can
>     also undo it by using diff-unified->context, so if I could replace
>     the large undo entries with just one entry that says "call
>     diff-unified->context" it would not be a problem any more.
>
> The idea of extensible undo entries is interesting, but using it for
> composite operations such as this would be unreliable.  It is better
> to undo them based on their actual edits.

I don't think it would be unreliable in practice.

In cua-mode, I also needed more advanced undo information to make undo
work correctly for the advanced rectangle commands.

IMO it would have been great if the standard undo machinery could have
done that for me, but to make it work, I have maintain a separate undo
list for cua with links into the standard undo list and I must use
explicit/tricky methods to clean up that list to keep it in sync with
GC triggered truncation of the undo-list.  Very cumbersome.

If the standard undo list just had some form of "eval this form to undo"
entry, it would give a lot of flexibility.

>
>                                                               The SES
>     spreadsheet also needs such a feature (and currently fakes it by using
>     a wrapper around primitive-undo).
>
> This seems like the right sort use for such a feature.
>
> However, the use of a wrapper around primitive-undo is very ugly.
> I think we need to do more to detect when such things are installed
> in Emacs, so we can systematically make sure they are not.

So this is really something that is needed by several packages.  The
problem with the hotch-potch approaches that you recommend is that
they most likely don't work very well together (if at all).

-- 
Kim F. Storm <address@hidden> http://www.cua.dk





reply via email to

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