Function: markdown-ts-table-delete-row
markdown-ts-table-delete-row is an interactive and byte-compiled
function defined in markdown-ts-mode.el.gz.
Signature
(markdown-ts-table-delete-row)
Documentation
Delete the table row at point.
If point is on the header or delimiter row, do nothing. If point is not at a table, do nothing.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/textmodes/markdown-ts-mode.el.gz
(defun markdown-ts-table-delete-row ()
"Delete the table row at point.
If point is on the header or delimiter row, do nothing.
If point is not at a table, do nothing."
(interactive)
(markdown-ts--barf-if-not-mode 'markdown-ts-table-delete-row)
(when-let* ((near (markdown-ts--table-body-row-near-pos nil t))
;; Bail if point is on the header or delimiter row — do
;; not silently delete a body row the user did not select.
((not (cdr near)))
(row (car near)))
(let ((current-column (current-column)))
(delete-region (treesit-node-start row)
(min (1+ (treesit-node-end row)) (point-max)))
(move-to-column current-column))))