[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: patch to include EasyPG to Emacs
From: |
Stefan Monnier |
Subject: |
Re: patch to include EasyPG to Emacs |
Date: |
Sun, 10 Feb 2008 10:44:58 -0500 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.0.50 (gnu/linux) |
> - provide epa-*-enable/disable commands for several "intrusive" features for
> other modes (dired, mail-mode, menu-bars),
Please define them as (global) minor modes instead,
Oh and (memq 'epa-mail-mode mail-mode-hook) is not a good test because
mail-mode-hook may be buffer-local and epa-mail-mode would be only be on
the global part of it. You can fix the test, but I recommend you don't:
just do the `remove-hook' without checking whether it's done redundantly
or not.
E.g.
(define-minor-mode epa-mail-mode
"Minor mode to hook EasyPG into Mail mode."
:global t
(remove-hook 'mail-mode-hook 'epa-mail-mode)
(if epa-mail-mode
(add-hook 'mail-mode-hook 'epa-mail-mode)))
-- Stefan
- patch to include EasyPG to Emacs, Daiki Ueno, 2008/02/06
- Re: patch to include EasyPG to Emacs, Richard Stallman, 2008/02/07
- Re: patch to include EasyPG to Emacs, Michael Olson, 2008/02/08
- Re: patch to include EasyPG to Emacs, Daiki Ueno, 2008/02/10
- Re: patch to include EasyPG to Emacs,
Stefan Monnier <=
- Re: patch to include EasyPG to Emacs, Daiki Ueno, 2008/02/10
- Re: patch to include EasyPG to Emacs, Daiki Ueno, 2008/02/10
- Re: patch to include EasyPG to Emacs, Michael Olson, 2008/02/10
- Re: patch to include EasyPG to Emacs, Daiki Ueno, 2008/02/10
- Re: patch to include EasyPG to Emacs, Michael Olson, 2008/02/10
- Re: patch to include EasyPG to Emacs, Stefan Monnier, 2008/02/10
- Re: patch to include EasyPG to Emacs, Dan Nicolaescu, 2008/02/10
- Re: patch to include EasyPG to Emacs, Daiki Ueno, 2008/02/10
- Re: patch to include EasyPG to Emacs, Daiki Ueno, 2008/02/11
- Re: patch to include EasyPG to Emacs, Michael Olson, 2008/02/11