Function: markdown-table-backward-cell

markdown-table-backward-cell is an interactive and byte-compiled function defined in markdown-mode.el.

Signature

(markdown-table-backward-cell)

Documentation

Go to the previous cell in the table.

Key Bindings

Source Code

;; Defined in ~/.emacs.d/elpa/markdown-mode-20260321.143/markdown-mode.el
(defun markdown-table-backward-cell ()
  "Go to the previous cell in the table."
  (interactive)
  (unless (markdown-table-at-point-p)
    (user-error "Not at a table"))
  (when markdown-table-align-p
    (markdown-table-align))
  (when (markdown-table-hline-at-point-p) (beginning-of-line 1))
  (condition-case nil
      (progn
        (re-search-backward "\\(?:^\\|[^\\]\\)|" (markdown-table-begin))
        ;; When this function is called while in the first cell in a
        ;; table, the point will now be at the beginning of a line. In
        ;; this case, we need to move past one additional table
        ;; boundary, the end of the table on the previous line.
        (when (= (point) (line-beginning-position))
          (re-search-backward "\\(?:^\\|[^\\]\\)|" (markdown-table-begin)))
        (re-search-backward "\\(?:^\\|[^\\]\\)|" (markdown-table-begin)))
    (error (user-error "Cannot move to previous table cell")))
  (when (looking-at "\\(?:^\\|[^\\]\\)| ?") (goto-char (match-end 0)))

  ;; This may have dropped point on the hline.
  (when (markdown-table-hline-at-point-p)
    (markdown-table-backward-cell)))