diff options
author | Richard M. Stallman <[email protected]> | 2003-04-30 12:03:53 +0000 |
---|---|---|
committer | Richard M. Stallman <[email protected]> | 2003-04-30 12:03:53 +0000 |
commit | ccbb9ed2e0673e4e69761abc32ceb973a1d3645e (patch) | |
tree | dac256c888c7968b319e60a45288e3b7a4435085 /src | |
parent | 167899c437fa059886c387fc05ffb6d4b2e83c2e (diff) |
(move_it_vertically_backward): Do the final big else even if nlines is 0.
(redisplay_internal): Finish the per-frame loop
even if redisplay is suspended by input.
Diffstat (limited to 'src')
-rw-r--r-- | src/xdisp.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/src/xdisp.c b/src/xdisp.c index 7c9a52cbba..18e57edb28 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -5823,10 +5823,14 @@ move_it_vertically_backward (it, dy) move_it_to (&it2, start_pos, -1, -1, -1, MOVE_TO_POS); xassert (IT_CHARPOS (*it) >= BEGV); + /* H is the actual vertical distance from the position in *IT + and the starting position. */ h = it2.current_y - it->current_y; + /* NLINES is the distance in number of lines. */ nlines = it2.vpos - it->vpos; - /* Correct IT's y and vpos position. */ + /* Correct IT's y and vpos position + so that they are relative to the starting point. */ it->vpos -= nlines; it->current_y -= h; @@ -5838,10 +5842,10 @@ move_it_vertically_backward (it, dy) move_it_by_lines (it, nlines, 1); xassert (IT_CHARPOS (*it) <= start_pos); } - else if (nlines) + else { - /* The y-position we try to reach. Note that h has been - subtracted in front of the if-statement. */ + /* The y-position we try to reach, relative to *IT. + Note that H has been subtracted in front of the if-statement. */ int target_y = it->current_y + h - dy; int y0 = it3.current_y; int y1 = line_bottom_y (&it3); @@ -9999,8 +10003,10 @@ redisplay_internal (preserve_echo_area) /* Update the display. */ set_window_update_flags (XWINDOW (f->root_window), 1); pause |= update_frame (f, 0, 0); +#if 0 /* Exiting the loop can leave the wrong value for buffer_shared. */ if (pause) break; +#endif if (n == size) { |