diff options
author | Glenn Morris <rgm@gnu.org> | 2020-10-10 07:50:18 -0700 |
---|---|---|
committer | Glenn Morris <rgm@gnu.org> | 2020-10-10 07:50:18 -0700 |
commit | 950911373c7e3a7527748b377935f4bfff694fe8 (patch) | |
tree | 1b2a244998f2285c4e571885e3741df67783c8c1 /src/xdisp.c | |
parent | 1006eb119849e4f81aa9a0b1c214a72bc2fbf8e3 (diff) | |
parent | acc9b461538d65190cd88f87fd997f733f382ad9 (diff) | |
download | emacs-950911373c7e3a7527748b377935f4bfff694fe8.tar.gz |
Merge from origin/emacs-27
acc9b46153 Fix merging of region face for non-ASCII characters
c2a13969e4 Make drag and drop on NS open all URLs (bug#43470)
Diffstat (limited to 'src/xdisp.c')
-rw-r--r-- | src/xdisp.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/xdisp.c b/src/xdisp.c index 9e8f4fc5ada..536bea69eb2 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -21998,13 +21998,14 @@ extend_face_to_end_of_line (struct it *it) in the text area has to be drawn to the end of the text area. */ it->glyph_row->fill_line_p = true; + const int orig_face_id = it->face_id; /* If current character of IT is not ASCII, make sure we have the ASCII face. This will be automatically undone the next time get_next_display_element returns a multibyte character. Note that the character will always be single byte in unibyte text. */ if (!ASCII_CHAR_P (it->c)) - it->face_id = FACE_FOR_CHAR (f, face, 0, -1, Qnil); + it->face_id = FACE_FOR_CHAR (f, face, 0, -1, Qnil); /* The default face, possibly remapped. */ struct face *default_face = @@ -22198,6 +22199,7 @@ extend_face_to_end_of_line (struct it *it) if (stretch_width < 0) it->glyph_row->x = stretch_width; } + it->face_id = orig_face_id; } else #endif /* HAVE_WINDOW_SYSTEM */ @@ -22207,7 +22209,6 @@ extend_face_to_end_of_line (struct it *it) struct text_pos saved_pos = it->position; Lisp_Object saved_object = it->object;; enum display_element_type saved_what = it->what; - int saved_face_id = it->face_id; it->what = IT_CHARACTER; memset (&it->position, 0, sizeof it->position); @@ -22310,7 +22311,7 @@ extend_face_to_end_of_line (struct it *it) it->object = saved_object; it->position = saved_pos; it->what = saved_what; - it->face_id = saved_face_id; + it->face_id = orig_face_id; } } |