aboutsummaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorEli Zaretskii2017-05-31 19:01:31 +0300
committerEli Zaretskii2017-05-31 19:01:31 +0300
commit140ddc321be96c03ef234a12c56cef97a078fc07 (patch)
tree96ea84c5cdcc8cfb9be7036bd30e702c62a736fb /doc
parenta415c8bccb917c247792c4ce8e77b2512b3414d6 (diff)
downloademacs-140ddc321be96c03ef234a12c56cef97a078fc07.tar.gz
emacs-140ddc321be96c03ef234a12c56cef97a078fc07.zip
Support lower bound on hscrolling when only current line scrolls
* doc/emacs/display.texi (Horizontal Scrolling): Document the new mode of auto-hscrolling only the current line. * src/xdisp.c (init_iterator): When hscrolling only the current line, apply the window's min_hscroll here, so that non-current lines will be hscrolled by that minimum. Suggested by Stephen Berman <stephen.berman@gmx.net>. (hscroll_window_tree): Account for window's min_hscroll when deciding whether to recompute the hscroll. (display_line): Subtract window's min_hscroll from x_incr, as that was already accounted for in init_iterator. (Bug#27008)
Diffstat (limited to 'doc')
-rw-r--r--doc/emacs/display.texi11
1 files changed, 9 insertions, 2 deletions
diff --git a/doc/emacs/display.texi b/doc/emacs/display.texi
index d07913cefbe..a0d0792eacc 100644
--- a/doc/emacs/display.texi
+++ b/doc/emacs/display.texi
@@ -308,7 +308,11 @@ displayed. When the text in a window is scrolled horizontally, text
308lines are truncated rather than continued (@pxref{Line Truncation}). 308lines are truncated rather than continued (@pxref{Line Truncation}).
309If a window shows truncated lines, Emacs performs automatic horizontal 309If a window shows truncated lines, Emacs performs automatic horizontal
310scrolling whenever point moves off the left or right edge of the 310scrolling whenever point moves off the left or right edge of the
311screen. To disable automatic horizontal scrolling, set the variable 311screen. By default, all the lines in the window are scrolled
312horizontally together, but if you set the variable
313@code{auto-hscroll-mode} to the special value of @code{current-line},
314only the line showing the cursor will be scrolled. To disable
315automatic horizontal scrolling entirely, set the variable
312@code{auto-hscroll-mode} to @code{nil}. Note that when the automatic 316@code{auto-hscroll-mode} to @code{nil}. Note that when the automatic
313horizontal scrolling is turned off, if point moves off the edge of the 317horizontal scrolling is turned off, if point moves off the edge of the
314screen, the cursor disappears to indicate that. (On text terminals, 318screen, the cursor disappears to indicate that. (On text terminals,
@@ -366,7 +370,10 @@ sufficiently large argument will restore the normal display.
366 If you use those commands to scroll a window horizontally, that sets 370 If you use those commands to scroll a window horizontally, that sets
367a lower bound for automatic horizontal scrolling. Automatic scrolling 371a lower bound for automatic horizontal scrolling. Automatic scrolling
368will continue to scroll the window, but never farther to the right 372will continue to scroll the window, but never farther to the right
369than the amount you previously set by @code{scroll-left}. 373than the amount you previously set by @code{scroll-left}. When
374@code{auto-hscroll-mode} is set to @code{current-line}, all the lines
375other than the one showing the cursor will be scrolled by that minimal
376amount.
370 377
371@node Narrowing 378@node Narrowing
372@section Narrowing 379@section Narrowing