0
0
mirror of https://github.com/vim/vim.git synced 2025-07-04 23:07:33 -04:00

updated for version 7.1-152

This commit is contained in:
Bram Moolenaar 2007-11-08 13:51:42 +00:00
parent e40e57c514
commit a443af88a4
2 changed files with 25 additions and 1 deletions

View File

@ -2599,6 +2599,7 @@ win_line(wp, lnum, startrow, endrow, nochange)
int syntax_attr = 0; /* attributes desired by syntax */ int syntax_attr = 0; /* attributes desired by syntax */
int has_syntax = FALSE; /* this buffer has syntax highl. */ int has_syntax = FALSE; /* this buffer has syntax highl. */
int save_did_emsg; int save_did_emsg;
int eol_hl_off = 0; /* 1 if highlighted char after EOL */
#endif #endif
#ifdef FEAT_SPELL #ifdef FEAT_SPELL
int has_spell = FALSE; /* this buffer has spell checking */ int has_spell = FALSE; /* this buffer has spell checking */
@ -4312,6 +4313,10 @@ win_line(wp, lnum, startrow, endrow, nochange)
{ {
#ifdef FEAT_SEARCH_EXTRA #ifdef FEAT_SEARCH_EXTRA
long prevcol = (long)(ptr - line) - (c == NUL); long prevcol = (long)(ptr - line) - (c == NUL);
/* we're not really at that column when skipping some text */
if ((wp->w_p_wrap ? wp->w_skipcol : wp->w_leftcol) > prevcol)
++prevcol;
#endif #endif
/* invert at least one char, used for Visual and empty line or /* invert at least one char, used for Visual and empty line or
@ -4408,11 +4413,20 @@ win_line(wp, lnum, startrow, endrow, nochange)
ScreenAttrs[off] = char_attr; ScreenAttrs[off] = char_attr;
#ifdef FEAT_RIGHTLEFT #ifdef FEAT_RIGHTLEFT
if (wp->w_p_rl) if (wp->w_p_rl)
{
--col; --col;
--off;
}
else else
#endif #endif
{
++col; ++col;
++off;
}
++vcol; ++vcol;
#ifdef FEAT_SYN_HL
eol_hl_off = 1;
#endif
} }
} }
@ -4422,6 +4436,14 @@ win_line(wp, lnum, startrow, endrow, nochange)
if (c == NUL) if (c == NUL)
{ {
#ifdef FEAT_SYN_HL #ifdef FEAT_SYN_HL
if (eol_hl_off > 0 && vcol - eol_hl_off == (long)wp->w_virtcol)
{
/* highlight last char after line */
--col;
--off;
--vcol;
}
/* Highlight 'cursorcolumn' past end of the line. */ /* Highlight 'cursorcolumn' past end of the line. */
if (wp->w_p_wrap) if (wp->w_p_wrap)
v = wp->w_skipcol; v = wp->w_skipcol;
@ -4432,7 +4454,7 @@ win_line(wp, lnum, startrow, endrow, nochange)
vcol = v + col - win_col_off(wp); vcol = v + col - win_col_off(wp);
if (wp->w_p_cuc if (wp->w_p_cuc
&& (int)wp->w_virtcol >= vcol && (int)wp->w_virtcol >= vcol - eol_hl_off
&& (int)wp->w_virtcol < W_WIDTH(wp) * (row - startrow + 1) && (int)wp->w_virtcol < W_WIDTH(wp) * (row - startrow + 1)
+ v + v
&& lnum != wp->w_cursor.lnum && lnum != wp->w_cursor.lnum

View File

@ -666,6 +666,8 @@ static char *(features[]) =
static int included_patches[] = static int included_patches[] =
{ /* Add new patch number below this line */ { /* Add new patch number below this line */
/**/
152,
/**/ /**/
151, 151,
/**/ /**/