[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Disabled commands (was: Risky local variable mechanism)
From: |
Stefan Monnier |
Subject: |
Disabled commands (was: Risky local variable mechanism) |
Date: |
Wed, 08 Feb 2006 07:48:13 -0500 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) |
> This looks very like the interface for enabling dangerous commands in
> novice.el that after asking a question with multiple choices can save
> in .emacs forms like:
> (put 'narrow-to-region 'disabled nil)
> (put 'narrow-to-defun 'disabled nil)
> (put 'downcase-region 'disabled nil)
> (put 'upcase-region 'disabled nil)
Indeed, that's a much better example.
While on this side-subject, any objection to the patch below?
Stefan
--- orig/lisp/files.el
+++ mod/lisp/files.el
@@ -3614,6 +3570,7 @@
(message (if arg "Modification-flag set"
"Modification-flag cleared"))
(set-buffer-modified-p arg))
+(put 'not-modified 'disabled t)
(defun toggle-read-only (&optional arg)
"Change whether this buffer is visiting its file read-only.
- Re: Risky local variable mechanism, (continued)
- Re: Risky local variable mechanism, Luc Teirlinck, 2006/02/08
- Re: Risky local variable mechanism, Stefan Monnier, 2006/02/08
- Re: Risky local variable mechanism, Luc Teirlinck, 2006/02/08
- Re: Risky local variable mechanism, Stefan Monnier, 2006/02/08
- Re: Risky local variable mechanism, Richard M. Stallman, 2006/02/09
- Re: Risky local variable mechanism, Richard M. Stallman, 2006/02/09
- Re: Risky local variable mechanism, Luc Teirlinck, 2006/02/10
- Re: Risky local variable mechanism, Juri Linkov, 2006/02/08
- Disabled commands (was: Risky local variable mechanism),
Stefan Monnier <=
- Re: Disabled commands (was: Risky local variable mechanism), Richard M. Stallman, 2006/02/09
- Re: Disabled commands, Stefan Monnier, 2006/02/09
- Re: Disabled commands, Miles Bader, 2006/02/09
- Re: Disabled commands, Eli Zaretskii, 2006/02/10
- Re: Disabled commands, Bill Wohler, 2006/02/13
- Re: Disabled commands, Kim F. Storm, 2006/02/13
- Re: Disabled commands, Giorgos Keramidas, 2006/02/13
- Re: Disabled commands, Romain Francoise, 2006/02/13
- Re: Disabled commands, Kevin Rodgers, 2006/02/09
- RE: Risky local variable mechanism, Drew Adams, 2006/02/08