truncate-lines t
buffer-read-only t)
(use-local-map epa-keys-mode-map)
- (set-keymap-parent (current-local-map) widget-keymap)
(make-local-variable 'font-lock-defaults)
(setq font-lock-defaults '(epa-font-lock-keywords t))
;; In XEmacs, auto-initialization of font-lock is not effective
;; if buffer-file-name is not set.
(font-lock-set-defaults)
- (widget-setup)
(make-local-variable 'epa-exit-buffer-function)
(run-hooks 'epa-keys-mode-hook))
(point-max)))
(goto-char point))
(epa-insert-keys context name mode)
- (epa-keys-mode))
+ (epa-keys-mode)
+ (widget-setup)
+ (set-keymap-parent (current-local-map) widget-keymap))
(make-local-variable 'epa-list-keys-arguments)
(setq epa-list-keys-arguments (list name mode protocol))
(goto-char (point-min))
(epa-mark)))
(epa-insert-keys context nil nil)))
(epa-keys-mode)
+ (widget-setup)
+ (set-keymap-parent (current-local-map) widget-keymap)
(setq epa-exit-buffer-function #'abort-recursive-edit)
(goto-char (point-min))
(pop-to-buffer (current-buffer)))
(epa-select-keys (epg-make-context) "Select keys for signing.
If no one is selected, default secret key is used. "
nil t)
- (if (y-or-n-p "Make a detached signature? ")
- 'detached
- (if (y-or-n-p "Make a cleartext signature? ")
- 'clear))))
+ (catch 'done
+ (while t
+ (message "Signature type (n,c,d,?) ")
+ (let ((c (read-char)))
+ (cond ((eq c ?c)
+ (throw 'done 'clear))
+ ((eq c ?d)
+ (throw 'done 'detached))
+ ((eq c ??)
+ (with-output-to-temp-buffer "*Help*"
+ (save-excursion
+ (set-buffer standard-output)
+ (insert "\
+n - Create a normal signature
+c - Create a cleartext signature
+d - Create a detached signature
+? - Show this help
+"))))
+ (t
+ (throw 'done nil))))))))
(let ((signature (concat file
(if (or epa-armor
(not (memq mode '(nil t normal detached))))