diff options
author | Bram Moolenaar <Bram@vim.org> | 2019-09-15 18:11:16 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2019-09-15 18:11:16 +0200 |
commit | 8ae54375cad51c3c05b7bb5600305062a1ebad1c (patch) | |
tree | b969d92ba8f239b200909bf676bbe9da9c3f6057 | |
parent | af9143833865a2d8311e57313023271720442f90 (diff) |
patch 8.1.2039: character from 'showbreak' does not use 'wincolor'v8.1.2039
Problem: Character from 'showbreak' does not use 'wincolor'. (Nick Jensen)
Solution: Mix with 'wincolor'. (closes #4938)
-rw-r--r-- | src/screen.c | 3 | ||||
-rw-r--r-- | src/testdir/dumps/Test_popupwin_showbreak.dump | 10 | ||||
-rw-r--r-- | src/testdir/test_popupwin.vim | 5 | ||||
-rw-r--r-- | src/version.c | 2 |
4 files changed, 13 insertions, 7 deletions
diff --git a/src/screen.c b/src/screen.c index 14b946538e..22b26b472e 100644 --- a/src/screen.c +++ b/src/screen.c @@ -4153,6 +4153,9 @@ win_line( * required when 'linebreak' is also set. */ if (tocol == vcol) tocol += n_extra; + // combine 'showbreak' with 'wincolor' + if (win_attr != 0) + char_attr = hl_combine_attr(win_attr, char_attr); # ifdef FEAT_SYN_HL // combine 'showbreak' with 'cursorline' if (cul_attr != 0) diff --git a/src/testdir/dumps/Test_popupwin_showbreak.dump b/src/testdir/dumps/Test_popupwin_showbreak.dump index e7d03d05cd..8ce0a7501b 100644 --- a/src/testdir/dumps/Test_popupwin_showbreak.dump +++ b/src/testdir/dumps/Test_popupwin_showbreak.dump @@ -1,10 +1,10 @@ >1+0&#ffffff0| @73 |2| @73 -|3| @73 -|4| @25|╔+0#0000001#ffd7ff255|═@17|╗| +0#0000000#ffffff0@27 -|5| @25|║+0#0000001#ffd7ff255| |a| |l|o|n|g| |l|i|n|e| |h|e|r|e| |║| +0#0000000#ffffff0@27 -|6| @25|╚+0#0000001#ffd7ff255|═@17|╝| +0#0000000#ffffff0@27 -|7| @73 +|3| @27|╔+0#0000001#ffd7ff255|═@13|╗| +0#0000000#ffffff0@29 +|4| @27|║+0#0000001#ffd7ff255| |a| |l|o|n|g| |l|i|n|e| @1|║| +0#0000000#ffffff0@29 +|5| @27|║+0#0000001#ffd7ff255| |>+0#4040ff13&@1| |h+0#0000001&|e|r|e| |t|h|a|t| |║| +0#0000000#ffffff0@29 +|6| @27|║+0#0000001#ffd7ff255| |>+0#4040ff13&@1| | +0#0000001&|w|r|a|p|s| @3|║| +0#0000000#ffffff0@29 +|7| @27|╚+0#0000001#ffd7ff255|═@13|╝| +0#0000000#ffffff0@29 |8| @73 |9| @73 @57|1|,|1| @10|T|o|p| diff --git a/src/testdir/test_popupwin.vim b/src/testdir/test_popupwin.vim index feb8ce37b8..de8a23f760 100644 --- a/src/testdir/test_popupwin.vim +++ b/src/testdir/test_popupwin.vim @@ -797,8 +797,9 @@ func Test_popup_with_showbreak() set showbreak=>>\ call setline(1, range(1, 20)) let winid = popup_dialog( - \ 'a long line here', - \ #{filter: 'popup_filter_yesno'}) + \ 'a long line here that wraps', + \ #{filter: 'popup_filter_yesno', + \ maxwidth: 12}) END call writefile(lines, 'XtestPopupShowbreak') let buf = RunVimInTerminal('-S XtestPopupShowbreak', #{rows: 10}) diff --git a/src/version.c b/src/version.c index 98e69d446f..a2f64177ad 100644 --- a/src/version.c +++ b/src/version.c @@ -758,6 +758,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 2039, +/**/ 2038, /**/ 2037, |