From e74fb0f735d41ec3f5ad8f51898a5eafbaf09ef2 Mon Sep 17 00:00:00 2001 From: Gerd Moellmann Date: Mon, 1 Oct 2001 10:52:55 +0000 Subject: [PATCH] (display_line): Set row's ends_in_newline_from_string_p. (try_window_id): Skip back over lines ending in a newline from a string. --- src/xdisp.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/xdisp.c b/src/xdisp.c index 00447cdb48d..09bc0f8185a 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -11495,7 +11495,8 @@ try_window_id (w) for instance. This is easier than to set up the iterator exactly, and it's not a frequent case, so the additional effort wouldn't really pay off. */ - while (MATRIX_ROW_ENDS_IN_MIDDLE_OF_CHAR_P (last_unchanged_at_beg_row) + while ((MATRIX_ROW_ENDS_IN_MIDDLE_OF_CHAR_P (last_unchanged_at_beg_row) + || last_unchanged_at_beg_row->ends_in_newline_from_string_p) && last_unchanged_at_beg_row > w->current_matrix->rows) --last_unchanged_at_beg_row; @@ -13004,6 +13005,8 @@ display_line (it) { int used_before = row->used[TEXT_AREA]; + row->ends_in_newline_from_string_p = STRINGP (it->object); + /* Add a space at the end of the line that is used to display the cursor there. */ append_space (it, 0); -- 2.39.5