Function: TeX-comment-or-uncomment-paragraph
TeX-comment-or-uncomment-paragraph is an interactive and byte-compiled
function defined in tex.el.
Signature
(TeX-comment-or-uncomment-paragraph)
Documentation
Comment or uncomment current paragraph.
Key Bindings
Source Code
;; Defined in ~/.emacs.d/elpa/auctex-14.1.2/tex.el
(defun TeX-comment-or-uncomment-paragraph ()
"Comment or uncomment current paragraph."
(interactive)
(if (TeX-in-commented-line)
(TeX-uncomment)
(save-excursion
(beginning-of-line)
;; Don't do anything if we are in an empty line. If this line
;; is followed by a lot of commented lines, this shall prevent
;; that mark-paragraph skips over these lines and marks a
;; paragraph outside the visible window which might get
;; commented without the user noticing.
(unless (looking-at "^[ \t]*$")
(mark-paragraph)
(comment-region (point) (mark))))))