aboutsummaryrefslogtreecommitdiffstats
path: root/doc/emacs
diff options
context:
space:
mode:
authorJuri Linkov <[email protected]>2007-10-06 22:23:41 +0000
committerJuri Linkov <[email protected]>2007-10-06 22:23:41 +0000
commita850cafb704a44871880711fc3eb687c47c4cd76 (patch)
treebfce66ef11e0fb7573fb5c07a0e455d62b3756b5 /doc/emacs
parent3220ac7f5e6bde4e38c5eb8a91c6366b1abbd86e (diff)
(Fill Commands): Document fill-paragraph-or-region.
(Fill Prefix, Format Indentation): Replace fill-paragraph with fill-paragraph-or-region.
Diffstat (limited to 'doc/emacs')
-rw-r--r--doc/emacs/text.texi43
1 files changed, 25 insertions, 18 deletions
diff --git a/doc/emacs/text.texi b/doc/emacs/text.texi
index 3a0e091ea4..9cfd4ffe92 100644
--- a/doc/emacs/text.texi
+++ b/doc/emacs/text.texi
@@ -486,9 +486,11 @@ The section on init files says how to arrange this permanently for yourself.
@table @kbd
@item M-q
-Fill current paragraph (@code{fill-paragraph}).
+Fill current paragraph or active region (@code{fill-paragraph-or-region}).
@item C-x f
Set the fill column (@code{set-fill-column}).
+@item M-x fill-paragraph
+Fill current paragraph (@code{fill-paragraph}).
@item M-x fill-region
Fill each paragraph in the region (@code{fill-region}).
@item M-x fill-region-as-paragraph
@@ -497,34 +499,39 @@ Fill the region, considering it as one paragraph.
Center a line.
@end table
-@kindex M-q
@findex fill-paragraph
- To refill a paragraph, use the command @kbd{M-q}
-(@code{fill-paragraph}). This operates on the paragraph that point is
-inside, or the one after point if point is between paragraphs.
-Refilling works by removing all the line-breaks, then inserting new ones
-where necessary.
+ To refill a paragraph, use @kbd{M-x fill-paragraph}. This operates
+on the paragraph that point is inside, or the one after point if point
+is between paragraphs. Refilling works by removing all the
+line-breaks, then inserting new ones where necessary.
@findex fill-region
To refill many paragraphs, use @kbd{M-x fill-region}, which
finds the paragraphs in the region and fills each of them.
+@kindex M-q
+@findex fill-paragraph-or-region
+ The command @kbd{M-q} (@code{fill-paragraph-or-region}), operates on
+the active region like @code{fill-region} when the mark is active in
+Transient Mark mode. Otherwise, it operates on the current paragraph
+like @code{fill-paragraph}.
+
@findex fill-region-as-paragraph
- @kbd{M-q} and @code{fill-region} use the same criteria as @kbd{M-h}
-for finding paragraph boundaries (@pxref{Paragraphs}). For more
-control, you can use @kbd{M-x fill-region-as-paragraph}, which refills
-everything between point and mark as a single paragraph. This command
-deletes any blank lines within the region, so separate blocks of text
-end up combined into one block.
+ @kbd{M-q}, @code{fill-paragraph} and @code{fill-region} use the same
+criteria as @kbd{M-h} for finding paragraph boundaries (@pxref{Paragraphs}).
+For more control, you can use @kbd{M-x fill-region-as-paragraph},
+which refills everything between point and mark as a single paragraph.
+This command deletes any blank lines within the region, so separate
+blocks of text end up combined into one block.
@cindex justification
A numeric argument to @kbd{M-q} tells it to @dfn{justify} the text
as well as filling it. This means that extra spaces are inserted to
make the right margin line up exactly at the fill column. To remove
the extra spaces, use @kbd{M-q} with no argument. (Likewise for
-@code{fill-region}.) Another way to control justification, and choose
-other styles of filling, is with the @code{justification} text
-property; see @ref{Format Justification}.
+@code{fill-paragraph} and @code{fill-region}.) Another way to control
+justification, and choose other styles of filling, is with the
+@code{justification} text property; see @ref{Format Justification}.
@kindex M-s @r{(Text mode)}
@cindex centering
@@ -588,7 +595,7 @@ fill prefix automatically (@pxref{Adaptive Fill}).
@item C-x .
Set the fill prefix (@code{set-fill-prefix}).
@item M-q
-Fill a paragraph using current fill prefix (@code{fill-paragraph}).
+Fill a paragraph using current fill prefix (@code{fill-paragraph-or-region}).
@item M-x fill-individual-paragraphs
Fill the region, considering each change of indentation as starting a
new paragraph.
@@ -2249,7 +2256,7 @@ margin width either with a numeric argument or in the minibuffer.
Sometimes, as a result of editing, the filling of a paragraph becomes
messed up---parts of the paragraph may extend past the left or right
-margins. When this happens, use @kbd{M-q} (@code{fill-paragraph}) to
+margins. When this happens, use @kbd{M-q} (@code{fill-paragraph-or-region}) to
refill the paragraph.
The fill prefix, if any, works in addition to the specified paragraph