Function: svg-embed

svg-embed is a byte-compiled function defined in svg.el.gz.

Signature

(svg-embed SVG IMAGE IMAGE-TYPE DATAP &rest ARGS)

Documentation

Insert IMAGE into the SVG structure.

IMAGE should be a file name if DATAP is nil, and a binary string otherwise. IMAGE-TYPE should be a MIME image type, like
"image/jpeg" or the like.

View in manual

Probably introduced at or before Emacs version 28.1.

Source Code

;; Defined in /usr/src/emacs/lisp/svg.el.gz
(defun svg-embed (svg image image-type datap &rest args)
  "Insert IMAGE into the SVG structure.
IMAGE should be a file name if DATAP is nil, and a binary string
otherwise.  IMAGE-TYPE should be a MIME image type, like
\"image/jpeg\" or the like."
  (svg--append
   svg
   (dom-node
    'image
    `((xlink:href . ,(svg--image-data image image-type datap))
      ,@(svg--arguments svg args)))))