aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman2005-03-29 21:06:20 +0000
committerRichard M. Stallman2005-03-29 21:06:20 +0000
commit19e7dd23ed5859155f955ff327bba9bfc4cf58de (patch)
tree7065c0a142133400f39a145126e7632e02f200c2
parent63cc3b0975bd3e25b11311b1dc7983afb22311d0 (diff)
downloademacs-19e7dd23ed5859155f955ff327bba9bfc4cf58de.tar.gz
emacs-19e7dd23ed5859155f955ff327bba9bfc4cf58de.zip
(Refill): Refer to Long Lines Mode.
(Longlines): New node. (Auto Fill): Don't index "word wrap" here. (Filling): Add Longlines to menu.
-rw-r--r--man/text.texi73
1 files changed, 63 insertions, 10 deletions
diff --git a/man/text.texi b/man/text.texi
index aba7496d5fc..958e18db8d5 100644
--- a/man/text.texi
+++ b/man/text.texi
@@ -403,13 +403,13 @@ Text}).
403* Fill Prefix:: Filling paragraphs that are indented 403* Fill Prefix:: Filling paragraphs that are indented
404 or in a comment, etc. 404 or in a comment, etc.
405* Adaptive Fill:: How Emacs can determine the fill prefix automatically. 405* Adaptive Fill:: How Emacs can determine the fill prefix automatically.
406* Longlines:: Editing text with very long lines.
406@end menu 407@end menu
407 408
408@node Auto Fill 409@node Auto Fill
409@subsection Auto Fill Mode 410@subsection Auto Fill Mode
410@cindex Auto Fill mode 411@cindex Auto Fill mode
411@cindex mode, Auto Fill 412@cindex mode, Auto Fill
412@cindex word wrap
413 413
414 @dfn{Auto Fill} mode is a minor mode in which lines are broken 414 @dfn{Auto Fill} mode is a minor mode in which lines are broken
415automatically when they become too wide. Breaking happens only when 415automatically when they become too wide. Breaking happens only when
@@ -474,16 +474,19 @@ you type or modify them in other ways. It provides an effect similar
474to typical word processor behavior. This works by running a 474to typical word processor behavior. This works by running a
475paragraph-filling command at suitable times. 475paragraph-filling command at suitable times.
476 476
477 When you are typing text, only characters which normally trigger
478auto filling, like the space character, will trigger refilling. This
479is to avoid making it too slow. Apart from self-inserting characters,
480other commands which modify the text cause refilling.
481
482 The current implementation is preliminary and probably not robust.
483We expect to improve on it.
484
485 To toggle the use of Refill mode in the current buffer, type 477 To toggle the use of Refill mode in the current buffer, type
486@kbd{M-x refill-mode}. 478@kbd{M-x refill-mode}. When you are typing text, only characters
479which normally trigger auto filling, like the space character, will
480trigger refilling. This is to avoid making it too slow. Apart from
481self-inserting characters, other commands which modify the text cause
482refilling.
483
484 The current implementation is preliminary and not robust. You can
485get better ``line wrapping'' behavior using Longlines mode.
486@xref{Longlines}. However, Longlines mode has an important
487side-effect: the newlines that it inserts for you are not saved to
488disk, so the files that you make with Longlines mode will appear to be
489completely unfilled if you edit them without Longlines mode.
487 490
488@node Fill Commands 491@node Fill Commands
489@subsection Explicit Fill Commands 492@subsection Explicit Fill Commands
@@ -745,6 +748,56 @@ line, and it should return the appropriate fill prefix based on that
745line. If it returns @code{nil}, that means it sees no fill prefix in 748line. If it returns @code{nil}, that means it sees no fill prefix in
746that line. 749that line.
747 750
751@node Longlines
752@subsection Long Lines Mode
753@cindex refilling text, word processor style
754@cindex modes, Long Lines
755@cindex word wrap
756@cindex Long Lines minor mode
757
758 Long Lines mode is a minor mode for @dfn{word wrapping}; it lets you
759edit ``unfilled'' text files, which Emacs would normally display as a
760bunch of extremely long lines. Many text editors, such as those built
761into many web browsers, normally do word wrapping.
762
763@findex longlines-mode
764 To enable Long Lines mode, type @kbd{M-x longlines-mode}. If the
765text is full of long lines, this will ``wrap'' them
766immediately---i.e., break up to fit in the window. As you edit the
767text, Long Lines mode automatically re-wraps lines by inserting or
768deleting @dfn{soft newlines} as necessary (@pxref{Hard and Soft
769Newlines}.) These soft newlines won't show up when you save the
770buffer into a file, or when you copy the text into the kill ring,
771clipboard, or a register.
772
773@findex longlines-auto-wrap
774 Word wrapping is @emph{not} the same as ordinary filling
775(@pxref{Fill Commands}). It does not contract multiple spaces into a
776single space, recognize fill prefixes (@pxref{Fill Prefix}), or
777perform adaptive filling (@pxref{Adaptive Fill}). The reason for this
778is that a wrapped line is still, conceptually, a single line. Each
779soft newline is equivalent to exactly one space in that long line, and
780vice versa. However, you can still call filling functions such as
781@kbd{M-q}, and these will work as expected, inserting soft newlines
782that won't show up on disk or when the text is copied. You can even
783rely entirely on the normal fill commands by turning off automatic
784line wrapping, with @kbd{C-u M-x longlines-auto-wrap}. To turn
785automatic line wrapping back on, type @kbd{M-x longlines-auto-wrap}.
786
787@findex longlines-show-hard-newlines
788 Whenever you type @kbd{RET}, you are inserting a hard newline. If
789you want to see where all the hard newlines are, type @kbd{M-x
790longlines-show-hard-newlines}. This will mark each hard newline with
791a special symbol. The same command with a prefix argument turns this
792display off.
793
794 Long Lines mode does not change normal text files that are already
795filled, since the existing newlines are considered hard newlines.
796Before Long Lines can do anything, you need to transform each
797paragraph into a long line. One way is to set @code{fill-column} to a
798large number (e.g., @kbd{C-u 9999 C-x f}), re-fill all the paragraphs,
799and then set @code{fill-column} back to its original value.
800
748@node Case 801@node Case
749@section Case Conversion Commands 802@section Case Conversion Commands
750@cindex case conversion 803@cindex case conversion