Function: tabulated-list-delete-entry

tabulated-list-delete-entry is a byte-compiled function defined in tabulated-list.el.gz.

Signature

(tabulated-list-delete-entry)

Documentation

Delete the Tabulated List entry at point.

Return a list (ID COLS), where ID is the ID of the deleted entry and COLS is a vector of its column descriptors. Move point to the beginning of the deleted entry. Return nil if there is no entry at point.

This function only changes the buffer contents; it does not alter tabulated-list-entries.

View in manual

Source Code

;; Defined in /usr/src/emacs/lisp/emacs-lisp/tabulated-list.el.gz
(defun tabulated-list-delete-entry ()
  "Delete the Tabulated List entry at point.
Return a list (ID COLS), where ID is the ID of the deleted entry
and COLS is a vector of its column descriptors.  Move point to
the beginning of the deleted entry.  Return nil if there is no
entry at point.

This function only changes the buffer contents; it does not alter
`tabulated-list-entries'."
  ;; Assume that each entry occupies one line.
  (let* ((id (tabulated-list-get-id))
	 (cols (tabulated-list-get-entry))
	 (inhibit-read-only t))
    (when cols
      (delete-region (pos-bol) (1+ (pos-eol)))
      (list id cols))))