[Top][All Lists]

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

Re: Undo discard prompt (was: [T. V. Raman] read-only modes should be us

From: T. V. Raman
Subject: Re: Undo discard prompt (was: [T. V. Raman] read-only modes should be using buffer-disable-undo?)
Date: Sun, 23 Jan 2005 10:21:16 -0800

Know about buffer-disable-undo - however life isn't as simple as just
calling that.

For instance, I experimented with it in shell-mode before suggesting
the robust macro solution; if you simply call buffer-disable-undo in
shell mode, things throw an error of the type "wrong-type argument
listp: t"
>>>>> "Luc" == Luc Teirlinck <address@hidden> writes:

    Luc> T. V. Raman wrote: Also, it might be useful to create a
    Luc> robust with-buffer-undo-disabled macro that authors can wrap
    Luc> around their code at points where they dont care about undo.

    Luc> If you want to get rid of undo completely, there is
    Luc> `buffer-disable-undo'.  If you want to disable it
    Luc> temporarily, there is:

    Luc> (let ((buffer-undo-list t)) ...)

    Luc> Also, the correct solution to the problem causing the prompt
    Luc> is not always to disable undo, completely or temporarily.  We
    Luc> have seen actual examples where the problem was caused by
    Luc> repeatedly appending undo info to the same old undo entry,
    Luc> whereas the correct solution was either to delete the old
    Luc> entry or put in an undo boundary.

    Luc> Sincerely,

    Luc> Luc.

Best Regards,

Email:  address@hidden
WWW:    http://emacspeak.sf.net/raman/
AIM:    TVRaman
PGP:    http://emacspeak.sf.net/raman/raman-almaden.asc

reply via email to

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