emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] emacs-25 8ee4c52: Improve documentatuon of 'truncate-parti


From: Eli Zaretskii
Subject: [Emacs-diffs] emacs-25 8ee4c52: Improve documentatuon of 'truncate-partial-width-windows'
Date: Sat, 26 Mar 2016 07:18:47 +0000

branch: emacs-25
commit 8ee4c52abc98e6522d812a29cfe57ffbdeb98144
Author: Eli Zaretskii <address@hidden>
Commit: Eli Zaretskii <address@hidden>

    Improve documentatuon of 'truncate-partial-width-windows'
    
    * src/xdisp.c (syms_of_xdisp) <truncate-partial-width-windows>:
    Clarify in the doc string how the width of partial-width windows
    is computed for the purposes of truncation decision.  (Bug#4338)
    
    * doc/emacs/windows.texi (Split Window): Clarify how the width of
    windows is calculated for the purposes of truncation decision.
    * doc/emacs/display.texi (Line Truncation): Remove a redundant
    index entry.
---
 doc/emacs/display.texi |    1 -
 doc/emacs/windows.texi |   12 ++++++++----
 src/xdisp.c            |    7 +++++--
 3 files changed, 13 insertions(+), 7 deletions(-)

diff --git a/doc/emacs/display.texi b/doc/emacs/display.texi
index c8987c2..01f899f 100644
--- a/doc/emacs/display.texi
+++ b/doc/emacs/display.texi
@@ -1601,7 +1601,6 @@ screen lines.  Setting the variable @code{truncate-lines} 
in any way
 makes it local to the current buffer; until that time, the default
 value, which is normally @code{nil}, is in effect.
 
address@hidden truncate-partial-width-windows
   If a split window becomes too narrow, Emacs may automatically enable
 line truncation.  @xref{Split Window}, for the variable
 @code{truncate-partial-width-windows} which controls this.
diff --git a/doc/emacs/windows.texi b/doc/emacs/windows.texi
index 7587f88..702963f 100644
--- a/doc/emacs/windows.texi
+++ b/doc/emacs/windows.texi
@@ -117,10 +117,14 @@ variable @code{truncate-lines} (@pxref{Line Truncation}); 
it is
 instead controlled by the variable
 @code{truncate-partial-width-windows}.  If the value of this variable
 is a positive integer (the default is 50), that specifies the minimum
-width for a partial-width window before automatic line truncation
-occurs; if the value is @code{nil}, automatic line truncation is
-disabled; and for any other address@hidden value, Emacs truncates
-lines in every partial-width window regardless of its width.
+total width for a partial-width window before automatic line
+truncation occurs; if the value is @code{nil}, automatic line
+truncation is disabled; and for any other address@hidden value, Emacs
+truncates lines in every partial-width window regardless of its width.
+The total width of a window is in column units as reported by
address@hidden (@pxref{Window Sizes,,, elisp, The Emacs
+Lisp Reference Manual}), it includes the fringes, the continuation and
+truncation glyphs, the margins, and the scroll bar.
 
   On text terminals, side-by-side windows are separated by a vertical
 divider which is drawn using the @code{vertical-border} face.
diff --git a/src/xdisp.c b/src/xdisp.c
index d6ee2de..d701306 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -31422,8 +31422,11 @@ Value is a number or a cons (WIDTH-DPI . HEIGHT-DPI).  
*/);
               Vtruncate_partial_width_windows,
     doc: /* Non-nil means truncate lines in windows narrower than the frame.
 For an integer value, truncate lines in each window narrower than the
-full frame width, provided the window width is less than that integer;
-otherwise, respect the value of `truncate-lines'.
+full frame width, provided the total window width in column units is less
+than that integer; otherwise, respect the value of `truncate-lines'.
+The total width of the window is as returned by `window-total-width', it
+includes the fringes, the continuation and truncation glyphs, the
+display margins (if any), and the scroll bar
 
 For any other non-nil value, truncate lines in all windows that do
 not span the full frame width.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]