;;; allout.el --- extensive outline mode for use alone and with other modes
-;; Copyright (C) 1992-1994, 2001-2012 Free Software Foundation, Inc.
+;; Copyright (C) 1992-1994, 2001-2013 Free Software Foundation, Inc.
;; Author: Ken Manheimer <ken dot manheimer at gmail...>
;; Maintainer: Ken Manheimer <ken dot manheimer at gmail...>
;;;_* Dependency loads
(require 'overlay)
(eval-when-compile
- ;; Most of the requires here are for stuff covered by autoloads, which
- ;; byte-compiling doesn't trigger.
- (require 'epg)
- (require 'epa)
- (require 'overlay)
;; `cl' is required for `assert'. `assert' is not covered by a standard
;; autoload, but it is a macro, so that eval-when-compile is sufficient
;; to byte-compile it in, or to do the require when the buffer evalled.
substitution string. If it's just a regexp, all its matches are removed
before the text is encrypted. If it's a regexp and a substitution, the
substitution is used against the regexp matches, a la `replace-match'.")
-(make-variable-buffer-local 'allout-encryption-text-removal-regexps)
+(make-variable-buffer-local 'allout-encryption-plaintext-sanitization-regexps)
;;;_ = allout-encryption-ciphertext-rejection-regexps
(defvar allout-encryption-ciphertext-rejection-regexps nil
"Variable for regexps matching plaintext to remove before encryption.
(defmacro allout-called-interactively-p ()
"A version of `called-interactively-p' independent of Emacs version."
;; ... to ease maintenance of allout without betraying deprecation.
- (if (equal (subr-arity (symbol-function 'called-interactively-p))
- '(0 . 0))
- '(called-interactively-p)
- '(called-interactively-p 'interactive)))
+ (if (ignore-errors (called-interactively-p 'interactive) t)
+ '(called-interactively-p 'interactive)
+ '(called-interactively-p)))
;;;_ = allout-inhibit-aberrance-doublecheck nil
;; In some exceptional moments, disparate topic depths need to be allowed
;; momentarily, eg when one topic is being yanked into another and they're
(cons (make-string
(1+ (truncate (if (zerop (car flat-index))
1
- (log10 (car flat-index)))))
+ (log (car flat-index) 10))))
? )
result)))
(setq flat-index (cdr flat-index)))
(cons (make-string
(1+ (truncate (if (zerop (car flat-index))
1
- (log10 (car flat-index)))))
+ (log (car flat-index) 10))))
? )
result)))
(setq flat-index (cdr flat-index)))
(run-hook-with-args 'allout-structure-added-functions
bullet-pos subtree-end))))
+
+(declare-function epg-context-set-passphrase-callback "epg"
+ (context passphrase-callback))
+(declare-function epg-list-keys "epg" (context &optional name mode))
+(declare-function epg-decrypt-string "epg" (context cipher))
+(declare-function epg-encrypt-string "epg"
+ (context plain recipients &optional sign always-trust))
+(declare-function epg-user-id-string "epg" (user-id))
+(declare-function epg-key-user-id-list "epg" (key))
+
;;;_ > allout-encrypt-string (text decrypt allout-buffer keymode-cue
;;; &optional rejected)
(defun allout-encrypt-string (text decrypt allout-buffer keymode-cue