diff --git a/ChangeLog b/ChangeLog index 289bc6c1..fc5976c3 100644 --- a/ChangeLog +++ b/ChangeLog @@ -90,7 +90,8 @@ CVS code - do_right_void(), need_horizontal_update(), need_vertical_update(), edit_scroll(), and edit_redraw(). All of these functions but the first two require the previous - versions of current and/or placewewant as parameters. Also + versions of current and/or placewewant as parameters, so that + they can redraw properly when the location has changed. Also rename the int refresh in do_delete() and do_backspace() to do_refresh so as not to conflict with refresh(). (DLR) - Add some comments better explaining what is disabled in diff --git a/src/winio.c b/src/winio.c index a82facb2..6e0c3a23 100644 --- a/src/winio.c +++ b/src/winio.c @@ -2610,7 +2610,8 @@ void edit_scroll(updown direction, int nlines) * updated. */ void edit_redraw(const filestruct *old_current, int old_pww) { - int do_refresh = need_vertical_update(old_pww); + int do_refresh = need_vertical_update(0) || + need_vertical_update(old_pww); const filestruct *foo; /* If either old_current or current is offscreen, refresh the screen @@ -2623,9 +2624,9 @@ void edit_redraw(const filestruct *old_current, int old_pww) return; } - /* Update old_current and current if we're not on the first page. - * If the mark is on, update all the lines between old_current and - * current too. */ + /* Update old_current and current if we're not on the first page + * and/or we're not on the same page as before. If the mark is on, + * update all the lines between old_current and current too. */ foo = old_current; while (foo != current) { if (do_refresh)