summaryrefslogtreecommitdiff
path: root/lisp/mh-e/mh-comp.el
diff options
context:
space:
mode:
authorStefan Kangas <stefan@marxist.se>2021-10-11 23:58:24 +0200
committerStefan Kangas <stefan@marxist.se>2021-10-12 01:55:57 +0200
commitf8d750135e90282864019b4484d0f0dec34cbd2f (patch)
tree64ad133fac3b0fee6364f64c7f1dfec21a9da2f4 /lisp/mh-e/mh-comp.el
parent76d75df8e7ae19c8aca3ab9a7fbee25fc3cf1e9e (diff)
downloademacs-f8d750135e90282864019b4484d0f0dec34cbd2f.tar.gz
Remove some more MH-E compat code
* lisp/mh-e/mh-acros.el (defun-mh, defmacro-mh): Make obsolete. * lisp/mh-e/mh-gnus.el (mh-gnus-local-map-property): Make obsolete. * lisp/mh-e/mh-mime.el (mh-insert-mime-security-button) (mh-insert-mime-button): Don't use above obsolete function. * lisp/mh-e/mh-gnus.el (mh-mm-text-html-renderer): Make obsolete. * lisp/mh-e/mh-mime.el (mh-mm-inline-media-tests) (mh-signature-highlight): Remove references to removed Gnus variable 'mm-inline-text-html-renderer'. * lisp/mh-e/mh-letter.el (mh-letter-complete): Make into obsolete function alias for 'completion-at-point'. Update callers. * lisp/mh-e/mh-e.el (mh-inc-spool-list, mh-show-use-xface-flag): * lisp/mh-e/mh-comp.el (mh-ascii-buffer-p): * lisp/mh-e/mh-show.el: * lisp/mh-e/mh-utils.el: Remove some references to XEmacs. * lisp/mh-e/mh-comp.el (mh-send-letter): Remove XEmacs and Emacs compat code. * lisp/mh-e/mh-compat.el (mh-display-completion-list): Remove compat code for Emacs 22 and earlier. * lisp/mh-e/mh-e.el (mh-inherit-face-flag) (mh-min-colors-defined-flag): Make XEmacs and Emacs 21 compat variables obsolete. (mh-face-data): Adjust to assume above variables are always t. * lisp/mh-e/mh-mime.el (mh-mime-button-map): Remove XEmacs and Emacs 20 compat code. * lisp/mh-e/mh-utils.el (mh-mapc): Make Emacs 20 compat function into obsolete function alias for mapc. Update callers. * lisp/mh-e/mh-xface.el (mh-show-xface-function, mh-show-xface): Remove Emacs 20 compat code.
Diffstat (limited to 'lisp/mh-e/mh-comp.el')
-rw-r--r--lisp/mh-e/mh-comp.el27
1 files changed, 5 insertions, 22 deletions
diff --git a/lisp/mh-e/mh-comp.el b/lisp/mh-e/mh-comp.el
index 8d5a4725520..4681ad885d0 100644
--- a/lisp/mh-e/mh-comp.el
+++ b/lisp/mh-e/mh-comp.el
@@ -304,21 +304,7 @@ message and scan line."
(let ((draft-buffer (current-buffer))
(file-name buffer-file-name)
(config mh-previous-window-config)
- ;; FIXME this is subtly different to select-message-coding-system.
- (coding-system-for-write
- (if (fboundp 'select-message-coding-system)
- (select-message-coding-system) ; Emacs has this since at least 21.1
- (if (and (local-variable-p 'buffer-file-coding-system
- (current-buffer)) ;XEmacs needs two args
- ;; We're not sure why, but buffer-file-coding-system
- ;; tends to get set to undecided-unix.
- (not (memq buffer-file-coding-system
- '(undecided undecided-unix undecided-dos))))
- buffer-file-coding-system
- (or (and (boundp 'sendmail-coding-system) sendmail-coding-system)
- (and (default-boundp 'buffer-file-coding-system)
- (default-value 'buffer-file-coding-system))
- 'utf-8)))))
+ (coding-system-for-write (select-message-coding-system)))
;; Older versions of spost do not support -msgid and -mime.
(unless mh-send-uses-spost-flag
;; Adding a Message-ID field looks good, makes it easier to search for
@@ -433,7 +419,7 @@ See also `mh-send'."
(mh-clean-msg-header (point-min) mh-new-draft-cleaned-headers nil)
(mh-insert-header-separator)
;; Merge in components
- (mh-mapc
+ (mapc
(lambda (header-field)
(let ((field (car header-field))
(value (cdr header-field))
@@ -697,7 +683,7 @@ message and scan line."
;; For "From", the first value wins, with the identity's "From"
;; trumping anything in the distcomps file.
(let ((components-file (mh-bare-components mh-dist-formfile)))
- (mh-mapc
+ (mapc
(lambda (header-field)
(let ((field (car header-field))
(value (cdr header-field))
@@ -1276,11 +1262,8 @@ discarded."
(set-syntax-table old-syntax-table))))
(defun mh-ascii-buffer-p ()
- "Check if current buffer is entirely composed of ASCII.
-The function doesn't work for XEmacs since `find-charset-region'
-doesn't exist there."
- (cl-loop for charset in (mh-funcall-if-exists
- find-charset-region (point-min) (point-max))
+ "Check if current buffer is entirely composed of ASCII."
+ (cl-loop for charset in (find-charset-region (point-min) (point-max))
unless (eq charset 'ascii) return nil
finally return t))