Mercurial > vim
diff src/screen.c @ 6018:79950dae1d7d v7.4.349
updated for version 7.4.349
Problem: When there are matches to highlight the whole window is redrawn,
which is slow.
Solution: Only redraw everything when lines were inserted or deleted.
Reset b_mod_xlines when needed. (Alexey Radkov)
author | Bram Moolenaar <bram@vim.org> |
---|---|
date | Wed, 02 Jul 2014 17:16:58 +0200 |
parents | ce284c205558 |
children | d42a1d3b74d4 |
line wrap: on
line diff
--- a/src/screen.c +++ b/src/screen.c @@ -1769,8 +1769,10 @@ win_update(wp) syntax_check_changed(lnum))) #endif #ifdef FEAT_SEARCH_EXTRA - /* match in fixed position might need redraw */ - || wp->w_match_head != NULL + /* match in fixed position might need redraw + * if lines were inserted or deleted */ + || (wp->w_match_head != NULL + && buf->b_mod_xlines != 0) #endif ))))) {