Function: message--image-part-string

message--image-part-string is a byte-compiled function defined in message.el.gz.

Signature

(message--image-part-string TYPE IMAGE)

Source Code

;; Defined in /usr/src/emacs/lisp/gnus/message.el.gz
(defun message--image-part-string (type image)
  (format "<#part type=\"%s\" disposition=inline data-encoding=base64 raw=t>\n%s\n<#/part>"
          type
	  ;; Get a base64 version of the image -- this avoids later
	  ;; complications if we're auto-saving the buffer and
	  ;; restoring from a file.
	  (with-temp-buffer
	    (set-buffer-multibyte nil)
	    (insert image)
	    (base64-encode-region (point-min) (point-max) t)
	    (buffer-string))))