Function: table--justify-cell-contents
table--justify-cell-contents is a byte-compiled function defined in
table.el.gz.
Signature
(table--justify-cell-contents JUSTIFY &optional PARAGRAPH)
Documentation
Justify the current cell contents.
JUSTIFY is a symbol left, center or right for horizontal, or top,
middle, bottom or none for vertical. When PARAGRAPH is non-nil the
justify operation is limited to the current paragraph.
Source Code
;; Defined in /usr/src/emacs/lisp/textmodes/table.el.gz
(defun table--justify-cell-contents (justify &optional paragraph)
"Justify the current cell contents.
JUSTIFY is a symbol `left', `center' or `right' for horizontal, or `top',
`middle', `bottom' or `none' for vertical. When PARAGRAPH is non-nil the
justify operation is limited to the current paragraph."
(table-with-cache-buffer
(let ((beg (point-min))
(end (point-max-marker))
(fill-column table-cell-info-width)
(adaptive-fill-mode nil)
(valign-symbols '(top middle bottom none)))
(unless paragraph
(if (memq justify valign-symbols)
(setq table-cell-info-valign
(if (eq justify 'none) nil justify))
(setq table-cell-info-justify justify)))
(save-excursion
(if paragraph
(let ((paragraph-start "\n"))
(forward-paragraph)
(or (bolp) (newline 1))
(set-marker end (point))
(setq beg (progn (forward-paragraph -1) (point)))))
(if (memq justify valign-symbols)
(table--valign)
(table--remove-eol-spaces beg end 'bol)
(let ((paragraph-start table-paragraph-start))
(fill-region beg end table-cell-info-justify))))
(setq table-inhibit-auto-fill-paragraph t)
(set-marker end nil)))
(table--update-cell 'now))