Function: woman2-IP
woman2-IP is a byte-compiled function defined in woman.el.gz.
Signature
(woman2-IP TO)
Documentation
.IP x i -- Same as .TP with tag x. Format paragraphs up to TO.
Source Code
;; Defined in /usr/src/emacs/lisp/woman.el.gz
(defun woman2-IP (to)
".IP x i -- Same as .TP with tag x. Format paragraphs up to TO."
(woman-interparagraph-space)
(if (eolp) ; no args
;; Like LP without resetting prevailing indent
(woman2-format-paragraphs to (+ woman-left-margin
woman-prevailing-indent))
(woman-forward-arg 'unquote)
(let ((i (woman2-get-prevailing-indent 'leave-eol)))
(beginning-of-line)
(woman-leave-blank-lines) ; must be here,
;;
;; The cvs.1 manpage contains some (possibly buggy) syntax that
;; confuses woman, although the man program displays it ok.
;; Most problems are caused by IP followed by another request on
;; the next line. Without the following hack, the second request
;; gets displayed raw in the output. Note that
;; woman2-tagged-paragraph also contains a hack for similar
;; issues (eg IP followed by SP).
;;
;; i) For IP followed by one or more IPs, we ignore all but the
;; last (mimic man). The hack in w-t-p would only work for two
;; consecutive IPs, and would use the first.
;; ii) For IP followed by SP followed by one or more requests,
;; do nothing. At least in cvs.1, there is usually another IP in
;; there somewhere.
(unless (or (looking-at "^\\.IP")
(and (looking-at "^\\.sp")
(save-excursion
(and (zerop (forward-line 1))
(looking-at woman-request-regexp)))))
(woman2-tagged-paragraph to i)))))