diff options
author | zeertzjq <zeertzjq@outlook.com> | 2024-02-12 22:53:20 +0100 |
---|---|---|
committer | Christian Brabandt <cb@256bit.org> | 2024-02-12 22:53:20 +0100 |
commit | f0a9d65e0a1d693cdfa964aa72de5b93b4cacdea (patch) | |
tree | a7bcca9cd0529aca96d62ff1b7bf8f96a00f11c3 /src/testdir/test_breakindent.vim | |
parent | b47fbb40837512cdd2d8c25eaf9952154836b99d (diff) |
patch 9.1.0103: 'breakindentopt' "min" not correct with 'signcolumn'v9.1.0103
Problem: 'breakindentopt' "min" works incorrectly with 'signcolumn'.
Solution: Use win_col_off() and win_col_off2().
(zeertzjq)
closes: #14014
Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
Diffstat (limited to 'src/testdir/test_breakindent.vim')
-rw-r--r-- | src/testdir/test_breakindent.vim | 34 |
1 files changed, 33 insertions, 1 deletions
diff --git a/src/testdir/test_breakindent.vim b/src/testdir/test_breakindent.vim index 9fde0f31ac..96d91c949c 100644 --- a/src/testdir/test_breakindent.vim +++ b/src/testdir/test_breakindent.vim @@ -733,7 +733,7 @@ func Test_breakindent20_list() \ "shall make no law ", \ ] call s:compare_lines(expect, lines) - " set minimum indent + " set minimum text width setl briopt=min:5 redraw! let lines = s:screen_lines2(1, 6, 20) @@ -1133,4 +1133,36 @@ func Test_breakindent_list_split() bwipe! endfunc +func Test_breakindent_min_with_signcol() + call s:test_windows('setl briopt=min:15 signcolumn=yes') + redraw! + let expect = [ + \ " abcdefghijklmn", + \ " opqrstuvwxyzABC", + \ " DEFGHIJKLMNOP " + \ ] + let lines = s:screen_lines(line('.'), 20) + call s:compare_lines(expect, lines) + setl briopt=min:17 + redraw! + let expect = [ + \ " abcdefghijklmn", + \ " opqrstuvwxyzABCDE", + \ " FGHIJKLMNOP " + \ ] + let lines = s:screen_lines(line('.'), 20) + call s:compare_lines(expect, lines) + setl briopt=min:19 + redraw! + let expect = [ + \ " abcdefghijklmn", + \ " opqrstuvwxyzABCDEF", + \ " GHIJKLMNOP " + \ ] + let lines = s:screen_lines(line('.'), 20) + call s:compare_lines(expect, lines) + + call s:close_windows() +endfunc + " vim: shiftwidth=2 sts=2 expandtab |