[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/src/xdisp.c
From: |
Richard M. Stallman |
Subject: |
[Emacs-diffs] Changes to emacs/src/xdisp.c |
Date: |
Wed, 30 Apr 2003 08:03:53 -0400 |
Index: emacs/src/xdisp.c
diff -c emacs/src/xdisp.c:1.827 emacs/src/xdisp.c:1.828
*** emacs/src/xdisp.c:1.827 Wed Apr 23 13:51:33 2003
--- emacs/src/xdisp.c Wed Apr 30 08:03:53 2003
***************
*** 5823,5832 ****
move_it_to (&it2, start_pos, -1, -1, -1, MOVE_TO_POS);
xassert (IT_CHARPOS (*it) >= BEGV);
h = it2.current_y - it->current_y;
nlines = it2.vpos - it->vpos;
! /* Correct IT's y and vpos position. */
it->vpos -= nlines;
it->current_y -= h;
--- 5823,5836 ----
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
! so that they are relative to the starting point. */
it->vpos -= nlines;
it->current_y -= h;
***************
*** 5838,5847 ****
move_it_by_lines (it, nlines, 1);
xassert (IT_CHARPOS (*it) <= start_pos);
}
! else if (nlines)
{
! /* The y-position we try to reach. 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);
--- 5842,5851 ----
move_it_by_lines (it, nlines, 1);
xassert (IT_CHARPOS (*it) <= start_pos);
}
! else
{
! /* 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,10006 ****
--- 10003,10012 ----
/* 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)
{