Function: fill-nonuniform-paragraphs

fill-nonuniform-paragraphs is an interactive and byte-compiled function defined in fill.el.gz.

Signature

(fill-nonuniform-paragraphs MIN MAX &optional JUSTIFYP CITATION-REGEXP)

Documentation

Fill paragraphs within the region, allowing varying indentation within each.

This command divides the region into "paragraphs", only at paragraph-separator lines, then fills each paragraph using as the fill prefix the smallest indentation of any line in the paragraph.

When calling from a program, pass range to fill as first two arguments.

Optional third and fourth arguments JUSTIFYP and CITATION-REGEXP: JUSTIFYP to justify paragraphs (prefix arg). When filling a mail message, pass a regexp for CITATION-REGEXP which will match the prefix of a line which is a citation marker plus whitespace, but no other kind of prefix. Also, if CITATION-REGEXP is non-nil, don't fill header lines.

View in manual

Probably introduced at or before Emacs version 19.1.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/textmodes/fill.el.gz
(defun fill-nonuniform-paragraphs (min max &optional justifyp citation-regexp)
  "Fill paragraphs within the region, allowing varying indentation within each.
This command divides the region into \"paragraphs\",
only at paragraph-separator lines, then fills each paragraph
using as the fill prefix the smallest indentation of any line
in the paragraph.

When calling from a program, pass range to fill as first two arguments.

Optional third and fourth arguments JUSTIFYP and CITATION-REGEXP:
JUSTIFYP to justify paragraphs (prefix arg).
When filling a mail message, pass a regexp for CITATION-REGEXP
which will match the prefix of a line which is a citation marker
plus whitespace, but no other kind of prefix.
Also, if CITATION-REGEXP is non-nil, don't fill header lines."
  (interactive (progn
		 (barf-if-buffer-read-only)
		 (list (region-beginning) (region-end)
		       (if current-prefix-arg 'full))))
  (let ((fill-individual-varying-indent t))
    (fill-individual-paragraphs min max justifyp citation-regexp)))