4 From: Bram Moolenaar <Bram@moolenaar.net>
6 Content-Type: text/plain; charset=ISO-8859-1
7 Content-Transfer-Encoding: 8bit
11 Problem: Unnecessary screen redrawing. (Jjgod Jiang)
12 Solution: Reset "must_redraw" after clearing the screen.
16 *** ../vim-7.1.044/src/screen.c Thu Jul 26 22:55:11 2007
17 --- src/screen.c Mon Jul 30 21:39:32 2007
22 if (type < must_redraw) /* use maximal type */
25 + /* must_redraw is reset here, so that when we run into some weird
26 + * reason to redraw while busy redrawing (e.g., asynchronous
27 + * scrolling), or update_topline() in win_update() will cause a
28 + * scroll, the screen will be redrawn later or in win_update(). */
38 + /* Trick: we want to avoid clearning the screen twice. screenclear() will
39 + * set "screen_cleared" to TRUE. The special value MAYBE (which is still
40 + * non-zero and thus not FALSE) will indicate that screenclear() was not
43 + screen_cleared = MAYBE;
46 * If there are no changes on the screen that require a complete redraw,
50 mid_end = wp->w_height;
51 if (lastwin == firstwin)
55 /* The screen was cleared, redraw the tab pages line. */
58 mid_end = wp->w_height;
59 if (lastwin == firstwin)
61 ! /* Clear the screen when it was not done by win_del_lines() or
62 ! * win_ins_lines() above, "screen_cleared" is FALSE or MAYBE
64 ! if (screen_cleared != TRUE)
67 /* The screen was cleared, redraw the tab pages line. */
76 + /* When win_del_lines() or win_ins_lines() caused the screen to be
77 + * cleared (only happens for the first window) or when screenclear()
78 + * was called directly above, "must_redraw" will have been set to
79 + * NOT_VALID, need to reset it here to avoid redrawing twice. */
80 + if (screen_cleared == TRUE)
85 *** ../vim-7.1.044/src/version.c Sun Jul 29 15:02:34 2007
86 --- src/version.c Mon Jul 30 21:58:06 2007
90 { /* Add new patch number below this line */
96 Be thankful to be in a traffic jam, because it means you own a car.
98 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
99 /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
100 \\\ download, build and distribute -- http://www.A-A-P.org ///
101 \\\ help me help AIDS victims -- http://ICCF-Holland.org ///