Function: mh-user-agent-compose

mh-user-agent-compose is an autoloaded and byte-compiled function defined in mh-comp.el.gz.

Signature

(mh-user-agent-compose &optional TO SUBJECT OTHER-HEADERS &rest IGNORED)

Documentation

Set up mail composition draft with the MH mail system.

This is the mail-user-agent entry point to MH-E. This function conforms to the contract specified by define-mail-user-agent which means that this function should accept the same arguments as compose-mail.

The optional arguments TO and SUBJECT specify recipients and the initial Subject field, respectively.

OTHER-HEADERS is an alist specifying additional header fields. Elements look like (HEADER . VALUE) where both HEADER and VALUE are strings.

Any additional arguments are IGNORED.

Source Code

;; Defined in /usr/src/emacs/lisp/mh-e/mh-comp.el.gz
;;;###autoload
(defun mh-user-agent-compose (&optional to subject other-headers &rest _ignored)
  "Set up mail composition draft with the MH mail system.
This is the `mail-user-agent' entry point to MH-E. This function
conforms to the contract specified by `define-mail-user-agent'
which means that this function should accept the same arguments
as `compose-mail'.

The optional arguments TO and SUBJECT specify recipients and the
initial Subject field, respectively.

OTHER-HEADERS is an alist specifying additional header fields.
Elements look like (HEADER . VALUE) where both HEADER and VALUE
are strings.

Any additional arguments are IGNORED."
  (mh-find-path)
  (let ((mh-error-if-no-draft t))
    (mh-send to "" subject)
    (while other-headers
      (mh-insert-fields (concat (car (car other-headers)) ":")
                        (cdr (car other-headers)))
      (setq other-headers (cdr other-headers)))))