[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Undo discard prompt
From: |
Richard Stallman |
Subject: |
Re: Undo discard prompt |
Date: |
Wed, 26 Jan 2005 20:56:40 -0500 |
I wrote:
I think this question should always be asked on the terminal,
temporarily suspending the keyboard macro.
Does this replacement do it?
(defun undo-outer-limit-truncate (size)
(when (or (null undo-extra-outer-limit)
(> size undo-extra-outer-limit))
;; Don't ask the question again unless it gets even bigger.
;; This applies, in particular, if the user quits from the question.
;; Such a quit quits out of GC, but something else will call GC
;; again momentarily. It will call this function again,
;; but we don't want to ask the question again.
(setq undo-extra-outer-limit (+ size 50000))
(if (let (use-dialog-box
executing-kbd-macro)
(yes-or-no-p (format "Buffer %s undo info is %d bytes long; discard
it? "
(buffer-name) size)))
(progn (setq buffer-undo-list nil)
(setq undo-extra-outer-limit nil)
t)
nil)))
- Re: Undo discard prompt, (continued)
- Re: Undo discard prompt, Richard Stallman, 2005/01/26
- Re: Undo discard prompt, Richard Stallman, 2005/01/26
- Re: Undo discard prompt, Richard Stallman, 2005/01/25
- Re: Undo discard prompt, Stefan Monnier, 2005/01/26
- Re: Undo discard prompt, Richard Stallman, 2005/01/26
- Undo discard prompt (was: [T. V. Raman] read-only modes should be using buffer-disable-undo?), T. V. Raman, 2005/01/23
- Re: Undo discard prompt (was: [T. V. Raman] read-only modes should be using buffer-disable-undo?), Luc Teirlinck, 2005/01/23
- Re: Undo discard prompt (was: [T. V. Raman] read-only modes should be using buffer-disable-undo?), Richard Stallman, 2005/01/24
- Re: Undo discard prompt, Stefan Monnier, 2005/01/25
- Re: Undo discard prompt, Richard Stallman, 2005/01/26
- Re: Undo discard prompt,
Richard Stallman <=
- Re: [T. V. Raman] read-only modes should be using buffer-disable-undo?, Richard Stallman, 2005/01/24
Re: [T. V. Raman] read-only modes should be using buffer-disable-undo?, T. V. Raman, 2005/01/23