diff options
author | zeertzjq <zeertzjq@outlook.com> | 2021-08-05 17:57:02 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2021-08-05 17:57:02 +0200 |
commit | 4f33bc20d7d5444e44d13f954e8219ad1abd26ef (patch) | |
tree | c207d3fc1e3253cc40cc15dc3d2e2fa325d56db1 /src/drawline.c | |
parent | 1b6acf02b7e685ecb87ccba52c91835a7519073e (diff) |
patch 8.2.3295: 'cursorline' should not apply to 'breakindent'v8.2.3295
Problem: 'cursorline' should not apply to 'breakindent'.
Solution: Make 'cursorline' apply to 'breakindent' and 'showbreak'
consistently. (closes #8684)
Diffstat (limited to 'src/drawline.c')
-rw-r--r-- | src/drawline.c | 32 |
1 files changed, 13 insertions, 19 deletions
diff --git a/src/drawline.c b/src/drawline.c index b4efbcbb87..deeaf5f168 100644 --- a/src/drawline.c +++ b/src/drawline.c @@ -1005,6 +1005,14 @@ win_line( // Skip this quickly when working on the text. if (draw_state != WL_LINE) { +#ifdef FEAT_SYN_HL + if (cul_screenline) + { + cul_attr = 0; + line_attr = line_attr_save; + } +#endif + #ifdef FEAT_CMDWIN if (draw_state == WL_CMDLINE - 1 && n_extra == 0) { @@ -1194,13 +1202,7 @@ win_line( char_attr = 0; # ifdef FEAT_DIFF if (diff_hlf != (hlf_T)0) - { char_attr = HL_ATTR(diff_hlf); -# ifdef FEAT_SYN_HL - if (cul_attr != 0) - char_attr = hl_combine_attr(char_attr, cul_attr); -# endif - } # endif p_extra = NULL; c_extra = ' '; @@ -1297,20 +1299,12 @@ win_line( } } #ifdef FEAT_SYN_HL - if (cul_screenline) + if (cul_screenline && draw_state == WL_LINE + && vcol >= left_curline_col + && vcol < right_curline_col) { - if (draw_state == WL_LINE - && vcol >= left_curline_col - && vcol < right_curline_col) - { - cul_attr = HL_ATTR(HLF_CUL); - line_attr = cul_attr; - } - else - { - cul_attr = 0; - line_attr = line_attr_save; - } + cul_attr = HL_ATTR(HLF_CUL); + line_attr = cul_attr; } #endif |