From c5db02d79276a06854907805d011aa2605a0b14b Mon Sep 17 00:00:00 2001 From: Jan Edmund Lazo Date: Sun, 31 Mar 2019 11:00:14 -0400 Subject: vim-patch:8.1.1073: space in number column is on wrong side with 'rightleft' set Problem: Space in number column is on wrong side with 'rightleft' set. Solution: Move the space to the text side. Add a test. https://github.com/vim/vim/commit/e73f911c53de1c87e39456ba20782f72a0ca8f4f --- src/nvim/screen.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'src/nvim/screen.c') diff --git a/src/nvim/screen.c b/src/nvim/screen.c index edddfd8ed3..fd070c6653 100644 --- a/src/nvim/screen.c +++ b/src/nvim/screen.c @@ -2772,8 +2772,15 @@ win_line ( if (wp->w_skipcol > 0) for (p_extra = extra; *p_extra == ' '; ++p_extra) *p_extra = '-'; - if (wp->w_p_rl) /* reverse line numbers */ - rl_mirror(extra); + if (wp->w_p_rl) { // reverse line numbers + // like rl_mirror(), but keep the space at the end + char_u *p2 = skiptowhite(extra) - 1; + for (char_u *p1 = extra; p1 < p2; p1++, p2--) { + const int t = *p1; + *p1 = *p2; + *p2 = t; + } + } p_extra = extra; c_extra = NUL; c_final = NUL; -- cgit From 3ae3d80bfb405b6e5a0189a5d93fcc9865c37580 Mon Sep 17 00:00:00 2001 From: Jan Edmund Lazo Date: Sun, 31 Mar 2019 12:25:41 -0400 Subject: vim-patch:8.1.1082: "Conceal" match is mixed up with 'hlsearch' match. Problem: "Conceal" match is mixed up with 'hlsearch' match. Solution: Check that a match is found, not a 'hlsearch' item. (Andy Massimino, closes vim/vim#4073) https://github.com/vim/vim/commit/ab62c19ea034d76632bbbf4265a9fc17e7508541 --- src/nvim/screen.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/nvim/screen.c') diff --git a/src/nvim/screen.c b/src/nvim/screen.c index fd070c6653..e66425d0c1 100644 --- a/src/nvim/screen.c +++ b/src/nvim/screen.c @@ -2963,8 +2963,11 @@ win_line ( shl->endcol = tmp_col; } shl->attr_cur = shl->attr; - if (cur != NULL && syn_name2id((char_u *)"Conceal") - == cur->hlg_id) { + // Match with the "Conceal" group results in hiding + // the match. + if (cur != NULL + && shl != &search_hl + && syn_name2id((char_u *)"Conceal") == cur->hlg_id) { has_match_conc = v == (long)shl->startcol ? 2 : 1; match_conc = cur->conceal_char; } else { -- cgit