Mercurial > emacs
comparison lisp/gnus/mml.el @ 31764:54ae1def18cf
Merge from Gnus trunk.
author | Dave Love <fx@gnu.org> |
---|---|
date | Wed, 20 Sep 2000 11:46:48 +0000 |
parents | 6b20b7e85e3c |
children | 18591e92c712 |
comparison
equal
deleted
inserted
replaced
31763:1d2b57dffb60 | 31764:54ae1def18cf |
---|---|
124 (setq tag (list 'part '(type . "text/plain")) | 124 (setq tag (list 'part '(type . "text/plain")) |
125 no-markup-p t | 125 no-markup-p t |
126 warn t)) | 126 warn t)) |
127 (setq raw (cdr (assq 'raw tag)) | 127 (setq raw (cdr (assq 'raw tag)) |
128 point (point) | 128 point (point) |
129 contents (if raw | 129 contents (mml-read-part (eq 'mml (car tag))) |
130 (mm-with-unibyte-current-buffer | |
131 (mml-read-part (eq 'mml (car tag)))) | |
132 (mml-read-part (eq 'mml (car tag)))) | |
133 charsets (if raw nil | 130 charsets (if raw nil |
134 (mm-find-mime-charset-region point (point)))) | 131 (mm-find-mime-charset-region point (point)))) |
135 (when (and (not raw) (memq nil charsets)) | 132 (when (and (not raw) (memq nil charsets)) |
136 (if (or (memq 'unknown-encoding mml-confirmation-set) | 133 (if (or (memq 'unknown-encoding mml-confirmation-set) |
137 (y-or-n-p | 134 (y-or-n-p |
350 (insert (cdr (assq 'contents cont))))) | 347 (insert (cdr (assq 'contents cont))))) |
351 (setq encoding (mm-encode-buffer type) | 348 (setq encoding (mm-encode-buffer type) |
352 coded (buffer-string)))) | 349 coded (buffer-string)))) |
353 (mml-insert-mime-headers cont type charset encoding) | 350 (mml-insert-mime-headers cont type charset encoding) |
354 (insert "\n") | 351 (insert "\n") |
355 (mm-with-unibyte-current-buffer | 352 (insert coded))) |
356 (insert coded)))) | |
357 ((eq (car cont) 'external) | 353 ((eq (car cont) 'external) |
358 (insert "Content-Type: message/external-body") | 354 (insert "Content-Type: message/external-body") |
359 (let ((parameters (mml-parameter-string | 355 (let ((parameters (mml-parameter-string |
360 cont '(expiration size permission))) | 356 cont '(expiration size permission))) |
361 (name (cdr (assq 'name cont)))) | 357 (name (cdr (assq 'name cont)))) |
850 (if (re-search-forward | 846 (if (re-search-forward |
851 (concat "^" (regexp-quote mail-header-separator) "\n") nil t) | 847 (concat "^" (regexp-quote mail-header-separator) "\n") nil t) |
852 (replace-match "\n")) | 848 (replace-match "\n")) |
853 (mml-to-mime) | 849 (mml-to-mime) |
854 (if raw | 850 (if raw |
855 (mm-disable-multibyte) | 851 (when (fboundp 'set-buffer-multibyte) |
852 (let ((s (buffer-string))) | |
853 ;; Insert the content into unibyte buffer. | |
854 (erase-buffer) | |
855 (mm-disable-multibyte) | |
856 (insert s))) | |
856 (let ((gnus-newsgroup-charset (car message-posting-charset))) | 857 (let ((gnus-newsgroup-charset (car message-posting-charset))) |
857 (run-hooks 'gnus-article-decode-hook) | 858 (run-hooks 'gnus-article-decode-hook) |
858 (let ((gnus-newsgroup-name "dummy")) | 859 (let ((gnus-newsgroup-name "dummy")) |
859 (gnus-article-prepare-display)))) | 860 (gnus-article-prepare-display)))) |
860 (fundamental-mode) | 861 (fundamental-mode) |