Function: format-insert-annotations
format-insert-annotations is a byte-compiled function defined in
format.el.gz.
Signature
(format-insert-annotations LIST &optional OFFSET)
Documentation
Apply list of annotations to buffer as write-region would.
Insert each element of the given LIST of buffer annotations at its appropriate place. Use second arg OFFSET if the annotations' locations are not relative to the beginning of the buffer: annotations will be inserted at their location-OFFSET+1 (i.e., the offset is treated as the position of the first character in the buffer).
Source Code
;; Defined in /usr/src/emacs/lisp/format.el.gz
;;;
;;; Encoding
;;;
(defun format-insert-annotations (list &optional offset)
"Apply list of annotations to buffer as `write-region' would.
Insert each element of the given LIST of buffer annotations at its
appropriate place. Use second arg OFFSET if the annotations' locations are
not relative to the beginning of the buffer: annotations will be inserted
at their location-OFFSET+1 \(i.e., the offset is treated as the position of
the first character in the buffer)."
(if (not offset)
(setq offset 0)
(setq offset (1- offset)))
(let ((l (reverse list)))
(while l
(goto-char (- (car (car l)) offset))
(insert (cdr (car l)))
(setq l (cdr l)))))