Function: markdown-table-get-cell
markdown-table-get-cell is a byte-compiled function defined in
markdown-mode.el.
Signature
(markdown-table-get-cell &optional N)
Documentation
Return the content of the cell in column N of current row.
N defaults to column at point. This function assumes point is on a table.
Source Code
;; Defined in ~/.emacs.d/elpa/markdown-mode-20260321.143/markdown-mode.el
(defun markdown-table-get-cell (&optional n)
"Return the content of the cell in column N of current row.
N defaults to column at point. This function assumes point is on
a table."
(and n (markdown-table-goto-column n))
(skip-chars-backward "^|\n") (backward-char 1)
(if (looking-at "|[^|\r\n]*")
(let* ((pos (match-beginning 0))
(val (buffer-substring (1+ pos) (match-end 0))))
(goto-char (min (line-end-position) (+ 2 pos)))
;; Trim whitespaces
(setq val (replace-regexp-in-string "\\`[ \t]+" "" val)
val (replace-regexp-in-string "[ \t]+\\'" "" val)))
(forward-char 1) ""))