diff options
| author | Eli Zaretskii | 2021-09-04 13:34:32 +0300 |
|---|---|---|
| committer | Eli Zaretskii | 2021-09-04 13:34:32 +0300 |
| commit | 0daad767047be33c0189d5e0131b126b49d35e6d (patch) | |
| tree | 892219cf9da45802f0e31184f5459d6a29525fad /src | |
| parent | a8de88e3300464eb382a65ea96da69f23d21ead2 (diff) | |
| download | emacs-0daad767047be33c0189d5e0131b126b49d35e6d.tar.gz emacs-0daad767047be33c0189d5e0131b126b49d35e6d.zip | |
Improve documentation of line truncation and wrapping
* doc/emacs/display.texi (Line Truncation, Visual Line Mode):
* doc/lispref/display.texi (Truncation): Document that turning on
line truncation disables wrapping, and vice versa.
* src/buffer.c (syms_of_buffer) <truncate-lines>:
* src/xdisp.c (syms_of_xdisp) <truncate-partial-width-windows>:
Warn against turning on when 'visual-line-mode' is in effect.
* lisp/simple.el (visual-line-mode): Document that this mode
disables line truncation. (Bug#29664)
Diffstat (limited to 'src')
| -rw-r--r-- | src/buffer.c | 5 | ||||
| -rw-r--r-- | src/xdisp.c | 5 |
2 files changed, 8 insertions, 2 deletions
diff --git a/src/buffer.c b/src/buffer.c index 100ebc7e2de..4eb7ab6d6ba 100644 --- a/src/buffer.c +++ b/src/buffer.c | |||
| @@ -5805,7 +5805,10 @@ Note that this is overridden by the variable | |||
| 5805 | `truncate-partial-width-windows' if that variable is non-nil | 5805 | `truncate-partial-width-windows' if that variable is non-nil |
| 5806 | and this buffer is not full-frame width. | 5806 | and this buffer is not full-frame width. |
| 5807 | 5807 | ||
| 5808 | Minibuffers set this variable to nil. */); | 5808 | Minibuffers set this variable to nil. |
| 5809 | |||
| 5810 | Don't set this to a non-nil value when `visual-line-mode' is | ||
| 5811 | turned on, as it could produce confusing results. */); | ||
| 5809 | 5812 | ||
| 5810 | DEFVAR_PER_BUFFER ("word-wrap", &BVAR (current_buffer, word_wrap), Qnil, | 5813 | DEFVAR_PER_BUFFER ("word-wrap", &BVAR (current_buffer, word_wrap), Qnil, |
| 5811 | doc: /* Non-nil means to use word-wrapping for continuation lines. | 5814 | doc: /* Non-nil means to use word-wrapping for continuation lines. |
diff --git a/src/xdisp.c b/src/xdisp.c index e853c8c2232..b2fcc165a9f 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -35136,7 +35136,10 @@ not span the full frame width. | |||
| 35136 | 35136 | ||
| 35137 | A value of nil means to respect the value of `truncate-lines'. | 35137 | A value of nil means to respect the value of `truncate-lines'. |
| 35138 | 35138 | ||
| 35139 | If `word-wrap' is enabled, you might want to reduce this. */); | 35139 | If `word-wrap' is enabled, you might want to reduce the value of this. |
| 35140 | |||
| 35141 | Don't set this to a non-nil value when `visual-line-mode' is | ||
| 35142 | turned on, as it could produce confusing results. */); | ||
| 35140 | Vtruncate_partial_width_windows = make_fixnum (50); | 35143 | Vtruncate_partial_width_windows = make_fixnum (50); |
| 35141 | 35144 | ||
| 35142 | DEFVAR_BOOL("word-wrap-by-category", word_wrap_by_category, doc: /* | 35145 | DEFVAR_BOOL("word-wrap-by-category", word_wrap_by_category, doc: /* |