[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master 1a850f4 3/3: Merge from origin/emacs-27
From: |
Glenn Morris |
Subject: |
master 1a850f4 3/3: Merge from origin/emacs-27 |
Date: |
Tue, 7 Jul 2020 10:55:41 -0400 (EDT) |
branch: master
commit 1a850f4b20d11938d68270147d3d5ebc3c4899f4
Merge: 1e3f94f 71fc003
Author: Glenn Morris <rgm@gnu.org>
Commit: Glenn Morris <rgm@gnu.org>
Merge from origin/emacs-27
71fc003860 (origin/emacs-27) Avoid infloop in 'format-mode-line'
247dcb4b1b Clarify the documentation of 'left/right-fringe' display spec
d453cee177 Minor improvement in ELisp manual
3c778c443c * doc/misc/tramp.texi (Customizing Methods): Fix typo.
---
doc/lispref/display.texi | 12 +++++++-----
doc/lispref/frames.texi | 13 +++++++------
doc/misc/tramp.texi | 9 +++++----
src/xdisp.c | 16 ++++++++++++++++
4 files changed, 35 insertions(+), 15 deletions(-)
diff --git a/doc/lispref/display.texi b/doc/lispref/display.texi
index 6fff199..d7aab4a 100644
--- a/doc/lispref/display.texi
+++ b/doc/lispref/display.texi
@@ -4274,9 +4274,10 @@ a display specification has the form
@noindent
@var{fringe} is either the symbol @code{left-fringe} or
@code{right-fringe}. @var{bitmap} is a symbol identifying the bitmap
-to display. The optional @var{face} names a face whose foreground
-color is used to display the bitmap; this face is automatically merged
-with the @code{fringe} face.
+to display. The optional @var{face} names a face whose foreground and
+background colors are to be used to display the bitmap; this face is
+automatically merged with the @code{fringe} face. If @var{face} is
+omitted, that means to use the @code{default} face.
For instance, to display an arrow in the left fringe, using the
@code{warning} face, you could say something like:
@@ -4980,8 +4981,9 @@ Margins}).
This display specification on any character of a line of text causes
the specified @var{bitmap} be displayed in the left or right fringes
for that line, instead of the characters that have the display
-specification. The optional @var{face} specifies the colors to be
-used for the bitmap. @xref{Fringe Bitmaps}, for the details.
+specification. The optional @var{face} specifies the face whose
+colors are to be used for the bitmap display. @xref{Fringe Bitmaps},
+for the details.
@item (space-width @var{factor})
This display specification affects all the space characters within the
diff --git a/doc/lispref/frames.texi b/doc/lispref/frames.texi
index a82b585..22d32c0 100644
--- a/doc/lispref/frames.texi
+++ b/doc/lispref/frames.texi
@@ -1599,12 +1599,13 @@ parameters represent the user's stated preference;
otherwise, use
This parameter specifies a relative position of the frame's
window-system window in the stacking (Z-) order of the frame's display.
-If this is @code{above}, the frame's window-system window is displayed
-above all other window-system windows that do not have the @code{above}
-property set. If this is @code{nil}, the frame's window is displayed below all
-windows that have the @code{above} property set and above all windows
-that have the @code{below} property set. If this is @code{below}, the
-frame's window is displayed below all windows that do not have the
+If this is @code{above}, the window-system will display the window
+that corresponds to the frame above all other window-system windows
+that do not have the @code{above} property set. If this is
+@code{nil}, the frame's window is displayed below all windows that
+have the @code{above} property set and above all windows that have the
+@code{below} property set. If this is @code{below}, the frame's
+window is displayed below all windows that do not have the
@code{below} property set.
To position the frame above or below a specific other frame use the
diff --git a/doc/misc/tramp.texi b/doc/misc/tramp.texi
index feead3d..c018033 100644
--- a/doc/misc/tramp.texi
+++ b/doc/misc/tramp.texi
@@ -1709,10 +1709,11 @@ Integration for LXD containers. A container is
accessed via
@item magit-tramp
@cindex method @option{git}
@cindex @option{git} method
-Browing git repositories with @code{magit}. A versioned file is accessed via
-@file{@trampfn{git,rev@@root-dir,/path/to/file}}. @samp{rev} is a git
-revision, and @samp{root-dir} is a virtual host name for the root
-directory, specified in @code{magit-tramp-hosts-alist}.
+Browsing git repositories with @code{magit}. A versioned file is
+accessed via @file{@trampfn{git,rev@@root-dir,/path/to/file}}.
+@samp{rev} is a git revision, and @samp{root-dir} is a virtual host
+name for the root directory, specified in
+@code{magit-tramp-hosts-alist}.
@item tramp-hdfs
@cindex method @option{hdfs}
diff --git a/src/xdisp.c b/src/xdisp.c
index 92afccc..97c55cd 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -26385,6 +26385,22 @@ decode_mode_spec (struct window *w, register int c,
int field_width,
startpos = marker_position (w->start);
startpos_byte = marker_byte_position (w->start);
height = WINDOW_TOTAL_LINES (w);
+ /* We cannot cope with w->start being outside of the
+ accessible portion of the buffer; in particular,
+ display_count_lines call below will infloop if called with
+ startpos_byte outside of the [BEGV_BYTE..ZV_BYTE] region.
+ Such w->start means we were called in some "creative" way
+ when the buffer's restriction was changed, but the window
+ wasn't yet redisplayed after that. If that happens, we
+ need to determine a new base line. */
+ if (!(BUF_BEGV_BYTE (b) <= startpos_byte
+ && startpos_byte <= BUF_ZV_BYTE (b)))
+ {
+ startpos = BUF_BEGV (b);
+ startpos_byte = BUF_BEGV_BYTE (b);
+ w->base_line_pos = 0;
+ w->base_line_number = 0;
+ }
/* If we decided that this buffer isn't suitable for line numbers,
don't forget that too fast. */