summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2015-03-20 17:16:27 +0100
committerBram Moolenaar <Bram@vim.org>2015-03-20 17:16:27 +0100
commitfbc25b20cbf29d6f9846e97875474f18e8d0c7be (patch)
tree21be794bc5cb47b267eaf5fb2ee0823f8af7e807
parentb1fc2bf29c560ca60515950812e8672c6dca1a4c (diff)
updated for version 7.4.667v7.4.667
Problem: 'colorcolumn' isn't drawn in a closed fold while 'cursorcolumn' is. (Carlos Pita) Solution: Make it consistent. (Christian Brabandt)
-rw-r--r--src/screen.c22
-rw-r--r--src/version.c2
2 files changed, 24 insertions, 0 deletions
diff --git a/src/screen.c b/src/screen.c
index 1addd0ad41..fd15ad18f3 100644
--- a/src/screen.c
+++ b/src/screen.c
@@ -2740,6 +2740,28 @@ fold_line(wp, fold_count, foldinfo, lnum, row)
}
#ifdef FEAT_SYN_HL
+ /* Show colorcolumn in the fold line, but let cursorcolumn override it. */
+ if (wp->w_p_cc_cols)
+ {
+ int i = 0;
+ int j = wp->w_p_cc_cols[i];
+ int old_txtcol = txtcol;
+
+ while (j > -1)
+ {
+ txtcol += j;
+ if (wp->w_p_wrap)
+ txtcol -= wp->w_skipcol;
+ else
+ txtcol -= wp->w_leftcol;
+ if (txtcol >= 0 && txtcol < W_WIDTH(wp))
+ ScreenAttrs[off + txtcol] = hl_combine_attr(
+ ScreenAttrs[off + txtcol], hl_attr(HLF_MC));
+ txtcol = old_txtcol;
+ j = wp->w_p_cc_cols[++i];
+ }
+ }
+
/* Show 'cursorcolumn' in the fold line. */
if (wp->w_p_cuc)
{
diff --git a/src/version.c b/src/version.c
index f9b47b17f0..c721e0784c 100644
--- a/src/version.c
+++ b/src/version.c
@@ -742,6 +742,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 667,
+/**/
666,
/**/
665,