[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/src/window.c
From: |
Kim F . Storm |
Subject: |
[Emacs-diffs] Changes to emacs/src/window.c |
Date: |
Mon, 21 Feb 2005 17:34:35 -0500 |
Index: emacs/src/window.c
diff -c emacs/src/window.c:1.495 emacs/src/window.c:1.496
*** emacs/src/window.c:1.495 Mon Jan 24 13:22:29 2005
--- emacs/src/window.c Mon Feb 21 22:34:34 2005
***************
*** 4763,4768 ****
--- 4763,4769 ----
else if (n < 0)
{
int charpos, bytepos;
+ int partial_p;
/* Save our position, for the preserve_y case. */
charpos = IT_CHARPOS (it);
***************
*** 4774,4780 ****
it.last_visible_y - this_scroll_margin - 1, -1,
MOVE_TO_POS | MOVE_TO_Y);
! if (IT_CHARPOS (it) == PT)
/* We found PT before we found the display margin, so PT is ok. */
;
else if (preserve_y >= 0)
--- 4775,4794 ----
it.last_visible_y - this_scroll_margin - 1, -1,
MOVE_TO_POS | MOVE_TO_Y);
! /* Save our position, in case it's correct. */
! charpos = IT_CHARPOS (it);
! bytepos = IT_BYTEPOS (it);
!
! /* See if point is on a partially visible line at the end. */
! if (it.what == IT_EOB)
! partial_p = it.current_y + it.ascent + it.descent > it.last_visible_y;
! else
! {
! move_it_by_lines (&it, 1, 1);
! partial_p = it.current_y > it.last_visible_y;
! }
!
! if (charpos == PT && !partial_p)
/* We found PT before we found the display margin, so PT is ok. */
;
else if (preserve_y >= 0)
***************
*** 4795,4808 ****
}
else
{
! /* Save our position, in case it's correct. */
! charpos = IT_CHARPOS (it);
! bytepos = IT_BYTEPOS (it);
!
! /* See if point is on a partially visible line at the end. */
! move_it_by_lines (&it, 1, 1);
!
! if (it.current_y > it.last_visible_y)
/* The last line was only partially visible, so back up two
lines to make sure we're on a fully visible line. */
{
--- 4809,4815 ----
}
else
{
! if (partial_p)
/* The last line was only partially visible, so back up two
lines to make sure we're on a fully visible line. */
{
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] Changes to emacs/src/window.c,
Kim F . Storm <=