rmail.el: Prefer #' to quote function names
* lisp/mail/rmail.el (rmail-pop-to-buffer, rmail-mode-map) (rmail-mode-1, rmail-generate-viewer-buffer, rmail-variables) (rmail-find-all-files, rmail-insert-inbox-text) (rmail-set-message-counters, rmail-only-expunge, rmail-reply) (rmail-resend, rmail-fontify-buffer-function) (rmail-unfontify-buffer-function, rmail-install-speedbar-variables) (after-save-hook): Use #' where applicable.
This commit is contained in:
parent
0b855e1465
commit
048eaadd8c
1 changed files with 81 additions and 79 deletions
|
@ -815,7 +815,7 @@ that knows the exact ordering of the \\( \\) subexpressions.")
|
|||
(defun rmail-pop-to-buffer (&rest args)
|
||||
"Like `pop-to-buffer', but with `split-width-threshold' set to nil."
|
||||
(let (split-width-threshold)
|
||||
(apply 'pop-to-buffer args)))
|
||||
(apply #'pop-to-buffer args)))
|
||||
|
||||
;; Perform BODY in the summary buffer
|
||||
;; in such a way that its cursor is properly updated in its own window.
|
||||
|
@ -1008,66 +1008,66 @@ The buffer is expected to be narrowed to just the header of the message."
|
|||
(defvar rmail-mode-map
|
||||
(let ((map (make-keymap)))
|
||||
(suppress-keymap map)
|
||||
(define-key map "a" 'rmail-add-label)
|
||||
(define-key map "b" 'rmail-bury)
|
||||
(define-key map "c" 'rmail-continue)
|
||||
(define-key map "d" 'rmail-delete-forward)
|
||||
(define-key map "\C-d" 'rmail-delete-backward)
|
||||
(define-key map "e" 'rmail-edit-current-message)
|
||||
(define-key map "a" #'rmail-add-label)
|
||||
(define-key map "b" #'rmail-bury)
|
||||
(define-key map "c" #'rmail-continue)
|
||||
(define-key map "d" #'rmail-delete-forward)
|
||||
(define-key map "\C-d" #'rmail-delete-backward)
|
||||
(define-key map "e" #'rmail-edit-current-message)
|
||||
;; If you change this, change the rmail-resend menu-item's :keys.
|
||||
(define-key map "f" 'rmail-forward)
|
||||
(define-key map "g" 'rmail-get-new-mail)
|
||||
(define-key map "h" 'rmail-summary)
|
||||
(define-key map "i" 'rmail-input)
|
||||
(define-key map "j" 'rmail-show-message)
|
||||
(define-key map "k" 'rmail-kill-label)
|
||||
(define-key map "l" 'rmail-summary-by-labels)
|
||||
(define-key map "\e\C-h" 'rmail-summary)
|
||||
(define-key map "\e\C-l" 'rmail-summary-by-labels)
|
||||
(define-key map "\e\C-r" 'rmail-summary-by-recipients)
|
||||
(define-key map "\e\C-s" 'rmail-summary-by-regexp)
|
||||
(define-key map "\e\C-f" 'rmail-summary-by-senders)
|
||||
(define-key map "\e\C-t" 'rmail-summary-by-topic)
|
||||
(define-key map "m" 'rmail-mail)
|
||||
(define-key map "\em" 'rmail-retry-failure)
|
||||
(define-key map "n" 'rmail-next-undeleted-message)
|
||||
(define-key map "\en" 'rmail-next-message)
|
||||
(define-key map "\e\C-n" 'rmail-next-labeled-message)
|
||||
(define-key map "o" 'rmail-output)
|
||||
(define-key map "\C-o" 'rmail-output-as-seen)
|
||||
(define-key map "p" 'rmail-previous-undeleted-message)
|
||||
(define-key map "\ep" 'rmail-previous-message)
|
||||
(define-key map "\e\C-p" 'rmail-previous-labeled-message)
|
||||
(define-key map "q" 'rmail-quit)
|
||||
(define-key map "r" 'rmail-reply)
|
||||
(define-key map "f" #'rmail-forward)
|
||||
(define-key map "g" #'rmail-get-new-mail)
|
||||
(define-key map "h" #'rmail-summary)
|
||||
(define-key map "i" #'rmail-input)
|
||||
(define-key map "j" #'rmail-show-message)
|
||||
(define-key map "k" #'rmail-kill-label)
|
||||
(define-key map "l" #'rmail-summary-by-labels)
|
||||
(define-key map "\e\C-h" #'rmail-summary)
|
||||
(define-key map "\e\C-l" #'rmail-summary-by-labels)
|
||||
(define-key map "\e\C-r" #'rmail-summary-by-recipients)
|
||||
(define-key map "\e\C-s" #'rmail-summary-by-regexp)
|
||||
(define-key map "\e\C-f" #'rmail-summary-by-senders)
|
||||
(define-key map "\e\C-t" #'rmail-summary-by-topic)
|
||||
(define-key map "m" #'rmail-mail)
|
||||
(define-key map "\em" #'rmail-retry-failure)
|
||||
(define-key map "n" #'rmail-next-undeleted-message)
|
||||
(define-key map "\en" #'rmail-next-message)
|
||||
(define-key map "\e\C-n" #'rmail-next-labeled-message)
|
||||
(define-key map "o" #'rmail-output)
|
||||
(define-key map "\C-o" #'rmail-output-as-seen)
|
||||
(define-key map "p" #'rmail-previous-undeleted-message)
|
||||
(define-key map "\ep" #'rmail-previous-message)
|
||||
(define-key map "\e\C-p" #'rmail-previous-labeled-message)
|
||||
(define-key map "q" #'rmail-quit)
|
||||
(define-key map "r" #'rmail-reply)
|
||||
;; I find I can't live without the default M-r command -- rms.
|
||||
;; (define-key rmail-mode-map "\er" 'rmail-search-backwards)
|
||||
(define-key map "s" 'rmail-expunge-and-save)
|
||||
(define-key map "\es" 'rmail-search)
|
||||
(define-key map "t" 'rmail-toggle-header)
|
||||
(define-key map "u" 'rmail-undelete-previous-message)
|
||||
(define-key map "v" 'rmail-mime)
|
||||
(define-key map "w" 'rmail-output-body-to-file)
|
||||
(define-key map "\C-c\C-w" 'rmail-widen)
|
||||
(define-key map "x" 'rmail-expunge)
|
||||
(define-key map "." 'rmail-beginning-of-message)
|
||||
(define-key map "/" 'rmail-end-of-message)
|
||||
(define-key map "<" 'rmail-first-message)
|
||||
(define-key map ">" 'rmail-last-message)
|
||||
(define-key map " " 'scroll-up-command)
|
||||
(define-key map [?\S-\ ] 'scroll-down-command)
|
||||
(define-key map "\177" 'scroll-down-command)
|
||||
(define-key map "?" 'describe-mode)
|
||||
(define-key map "\C-c\C-d" 'rmail-epa-decrypt)
|
||||
(define-key map "\C-c\C-s\C-d" 'rmail-sort-by-date)
|
||||
(define-key map "\C-c\C-s\C-s" 'rmail-sort-by-subject)
|
||||
(define-key map "\C-c\C-s\C-a" 'rmail-sort-by-author)
|
||||
(define-key map "\C-c\C-s\C-r" 'rmail-sort-by-recipient)
|
||||
(define-key map "\C-c\C-s\C-c" 'rmail-sort-by-correspondent)
|
||||
(define-key map "\C-c\C-s\C-l" 'rmail-sort-by-lines)
|
||||
(define-key map "\C-c\C-s\C-k" 'rmail-sort-by-labels)
|
||||
(define-key map "\C-c\C-n" 'rmail-next-same-subject)
|
||||
(define-key map "\C-c\C-p" 'rmail-previous-same-subject)
|
||||
;; (define-key rmail-mode-map "\er" #'rmail-search-backwards)
|
||||
(define-key map "s" #'rmail-expunge-and-save)
|
||||
(define-key map "\es" #'rmail-search)
|
||||
(define-key map "t" #'rmail-toggle-header)
|
||||
(define-key map "u" #'rmail-undelete-previous-message)
|
||||
(define-key map "v" #'rmail-mime)
|
||||
(define-key map "w" #'rmail-output-body-to-file)
|
||||
(define-key map "\C-c\C-w" #'rmail-widen)
|
||||
(define-key map "x" #'rmail-expunge)
|
||||
(define-key map "." #'rmail-beginning-of-message)
|
||||
(define-key map "/" #'rmail-end-of-message)
|
||||
(define-key map "<" #'rmail-first-message)
|
||||
(define-key map ">" #'rmail-last-message)
|
||||
(define-key map " " #'scroll-up-command)
|
||||
(define-key map [?\S-\ ] #'scroll-down-command)
|
||||
(define-key map "\177" #'scroll-down-command)
|
||||
(define-key map "?" #'describe-mode)
|
||||
(define-key map "\C-c\C-d" #'rmail-epa-decrypt)
|
||||
(define-key map "\C-c\C-s\C-d" #'rmail-sort-by-date)
|
||||
(define-key map "\C-c\C-s\C-s" #'rmail-sort-by-subject)
|
||||
(define-key map "\C-c\C-s\C-a" #'rmail-sort-by-author)
|
||||
(define-key map "\C-c\C-s\C-r" #'rmail-sort-by-recipient)
|
||||
(define-key map "\C-c\C-s\C-c" #'rmail-sort-by-correspondent)
|
||||
(define-key map "\C-c\C-s\C-l" #'rmail-sort-by-lines)
|
||||
(define-key map "\C-c\C-s\C-k" #'rmail-sort-by-labels)
|
||||
(define-key map "\C-c\C-n" #'rmail-next-same-subject)
|
||||
(define-key map "\C-c\C-p" #'rmail-previous-same-subject)
|
||||
|
||||
|
||||
(define-key map [menu-bar] (make-sparse-keymap))
|
||||
|
@ -1344,9 +1344,9 @@ Instead, these commands are available:
|
|||
(setq local-abbrev-table text-mode-abbrev-table)
|
||||
;; Functions to support buffer swapping:
|
||||
(add-hook 'write-region-annotate-functions
|
||||
'rmail-write-region-annotate nil t)
|
||||
(add-hook 'kill-buffer-hook 'rmail-mode-kill-buffer-hook nil t)
|
||||
(add-hook 'change-major-mode-hook 'rmail-change-major-mode-hook nil t))
|
||||
#'rmail-write-region-annotate nil t)
|
||||
(add-hook 'kill-buffer-hook #'rmail-mode-kill-buffer-hook nil t)
|
||||
(add-hook 'change-major-mode-hook #'rmail-change-major-mode-hook nil t))
|
||||
|
||||
(defun rmail-generate-viewer-buffer ()
|
||||
"Return a reusable buffer suitable for viewing messages.
|
||||
|
@ -1363,7 +1363,7 @@ Create the buffer if necessary."
|
|||
(file-name-nondirectory
|
||||
(or buffer-file-name (buffer-name)))))))
|
||||
(with-current-buffer newbuf
|
||||
(add-hook 'kill-buffer-hook 'rmail-view-buffer-kill-buffer-hook nil t))
|
||||
(add-hook 'kill-buffer-hook #'rmail-view-buffer-kill-buffer-hook nil t))
|
||||
newbuf)))
|
||||
|
||||
(defun rmail-swap-buffers ()
|
||||
|
@ -1479,7 +1479,7 @@ If so restore the actual mbox message collection."
|
|||
;; Don't turn off auto-saving based on the size of the buffer
|
||||
;; because that code does not understand buffer-swapping.
|
||||
(setq-local auto-save-include-big-deletions t)
|
||||
(setq-local revert-buffer-function 'rmail-revert)
|
||||
(setq-local revert-buffer-function #'rmail-revert)
|
||||
(setq-local font-lock-defaults
|
||||
'(rmail-font-lock-keywords
|
||||
t t nil nil
|
||||
|
@ -1490,7 +1490,7 @@ If so restore the actual mbox message collection."
|
|||
(setq-local file-precious-flag t)
|
||||
(setq-local desktop-save-buffer t)
|
||||
(setq-local save-buffer-coding-system 'no-conversion)
|
||||
(setq next-error-move-function 'rmail-next-error-move))
|
||||
(setq next-error-move-function #'rmail-next-error-move))
|
||||
|
||||
;; Handle M-x revert-buffer done in an rmail-mode buffer.
|
||||
(defun rmail-revert (arg noconfirm)
|
||||
|
@ -1606,7 +1606,7 @@ The duplicate copy goes into the Rmail file just after the original."
|
|||
(files (directory-files start t rmail-secondary-file-regexp)))
|
||||
;; Sort here instead of in directory-files
|
||||
;; because this list is usually much shorter.
|
||||
(sort files 'string<))))
|
||||
(sort files #'string<))))
|
||||
|
||||
(defun rmail-list-to-menu (menu-name l action &optional full-name)
|
||||
(let ((menu (make-sparse-keymap menu-name))
|
||||
|
@ -2026,7 +2026,7 @@ Value is the size of the newly read mail after conversion."
|
|||
rmail-movemail-flags)
|
||||
(list file tofile)
|
||||
(if password (list password) nil))))
|
||||
(apply 'call-process args))
|
||||
(apply #'call-process args))
|
||||
(if (not (buffer-modified-p errors))
|
||||
;; No output => movemail won
|
||||
nil
|
||||
|
@ -2518,7 +2518,7 @@ Output a helpful message unless NOMSG is non-nil."
|
|||
;; which will never be used.
|
||||
(push nil messages-head)
|
||||
(push ?0 deleted-head)
|
||||
(setq rmail-message-vector (apply 'vector messages-head)
|
||||
(setq rmail-message-vector (apply #'vector messages-head)
|
||||
rmail-deleted-vector (concat deleted-head))
|
||||
|
||||
(setq rmail-summary-vector (make-vector rmail-total-messages nil)
|
||||
|
@ -3605,10 +3605,10 @@ If `rmail-confirm-expunge' is non-nil, ask user to confirm."
|
|||
(cons (aref messages number) nil)))
|
||||
(setq rmail-current-message new-message-number
|
||||
rmail-total-messages counter
|
||||
rmail-message-vector (apply 'vector messages-head)
|
||||
rmail-message-vector (apply #'vector messages-head)
|
||||
rmail-deleted-vector (make-string (1+ counter) ?\s)
|
||||
rmail-summary-vector (vconcat (nreverse new-summary))
|
||||
rmail-msgref-vector (apply 'vector (nreverse new-msgref))
|
||||
rmail-msgref-vector (apply #'vector (nreverse new-msgref))
|
||||
win t)))
|
||||
(message "Expunging deleted messages...done")
|
||||
(if (not win)
|
||||
|
@ -3891,7 +3891,7 @@ use \\[mail-yank-original] to yank the original message into it."
|
|||
(if (or references message-id)
|
||||
(list (cons "References" (if references
|
||||
(concat
|
||||
(mapconcat 'identity references " ")
|
||||
(mapconcat #'identity references " ")
|
||||
" " message-id)
|
||||
message-id)))))))
|
||||
|
||||
|
@ -4089,7 +4089,7 @@ typically for purposes of moderating a list."
|
|||
(insert "Resent-Bcc: " (user-login-name) "\n"))
|
||||
(insert "Resent-To: " (if (stringp address)
|
||||
address
|
||||
(mapconcat 'identity address ",\n\t"))
|
||||
(mapconcat #'identity address ",\n\t"))
|
||||
"\n")
|
||||
;; Expand abbrevs in the recipients.
|
||||
(save-excursion
|
||||
|
@ -4335,7 +4335,7 @@ This has an effect only if a summary buffer exists."
|
|||
|
||||
(defun rmail-fontify-buffer-function ()
|
||||
;; This function's symbol is bound to font-lock-fontify-buffer-function.
|
||||
(add-hook 'rmail-show-message-hook 'rmail-fontify-message nil t)
|
||||
(add-hook 'rmail-show-message-hook #'rmail-fontify-message nil t)
|
||||
;; If we're already showing a message, fontify it now.
|
||||
(if rmail-current-message (rmail-fontify-message))
|
||||
;; Prevent Font Lock mode from kicking in.
|
||||
|
@ -4346,7 +4346,7 @@ This has an effect only if a summary buffer exists."
|
|||
(with-silent-modifications
|
||||
(save-restriction
|
||||
(widen)
|
||||
(remove-hook 'rmail-show-message-hook 'rmail-fontify-message t)
|
||||
(remove-hook 'rmail-show-message-hook #'rmail-fontify-message t)
|
||||
(remove-text-properties (point-min) (point-max) '(rmail-fontified nil))
|
||||
(font-lock-default-unfontify-buffer))))
|
||||
|
||||
|
@ -4381,11 +4381,12 @@ browsing, and moving of messages."
|
|||
"Install those variables used by speedbar to enhance rmail."
|
||||
(unless rmail-speedbar-key-map
|
||||
(setq rmail-speedbar-key-map (speedbar-make-specialized-keymap))
|
||||
(define-key rmail-speedbar-key-map "e" 'speedbar-edit-line)
|
||||
(define-key rmail-speedbar-key-map "r" 'speedbar-edit-line)
|
||||
(define-key rmail-speedbar-key-map "\C-m" 'speedbar-edit-line)
|
||||
(declare-function speedbar-edit-line "speedbar")
|
||||
(define-key rmail-speedbar-key-map "e" #'speedbar-edit-line)
|
||||
(define-key rmail-speedbar-key-map "r" #'speedbar-edit-line)
|
||||
(define-key rmail-speedbar-key-map "\C-m" #'speedbar-edit-line)
|
||||
(define-key rmail-speedbar-key-map "M"
|
||||
'rmail-speedbar-move-message-to-folder-on-line)))
|
||||
#'rmail-speedbar-move-message-to-folder-on-line)))
|
||||
|
||||
;; Mouse-3.
|
||||
(defvar rmail-speedbar-menu-items
|
||||
|
@ -4829,7 +4830,8 @@ Content-Transfer-Encoding: base64\n")
|
|||
(with-current-buffer
|
||||
(if (rmail-buffers-swapped-p) rmail-buffer rmail-view-buffer)
|
||||
(setq buffer-file-coding-system rmail-message-encoding))))
|
||||
(add-hook 'after-save-hook 'rmail-after-save-hook)
|
||||
;; FIXME: Don't do it globally!!
|
||||
(add-hook 'after-save-hook #'rmail-after-save-hook)
|
||||
|
||||
|
||||
;;; Mailing list support
|
||||
|
|
Loading…
Add table
Reference in a new issue