aboutsummaryrefslogtreecommitdiffstats
path: root/src/window.c
diff options
context:
space:
mode:
authorRichard M. Stallman <[email protected]>2002-09-05 02:36:22 +0000
committerRichard M. Stallman <[email protected]>2002-09-05 02:36:22 +0000
commit1de65f5131196f888384c154ba1c0fe0a6634a8c (patch)
treeb37a1f7bd70d9b01caee8c2b91dbf4c655bc0a3c /src/window.c
parent77d11aec5142e07dbebbee6c1a08ca3c826e6b8f (diff)
(displayed_window_lines): Correct for one-off bug
in HEIGHT on non-window displays.
Diffstat (limited to 'src/window.c')
-rw-r--r--src/window.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/window.c b/src/window.c
index 616afd6bc5..c629a30cb7 100644
--- a/src/window.c
+++ b/src/window.c
@@ -4653,6 +4653,15 @@ displayed_window_lines (w)
move_it_vertically (&it, height);
bottom_y = line_bottom_y (&it);
+ /* rms: On a non-window display,
+ the value of it.vpos at the bottom of the screen
+ seems to be 1 larger than window_box_height (w).
+ This kludge fixes a bug whereby (move-to-window-line -1)
+ when ZV is on the last screen line
+ moves to the previous screen line instead of the last one. */
+ if (! FRAME_WINDOW_P (XFRAME (w->frame)))
+ height++;
+
/* Add in empty lines at the bottom of the window. */
if (bottom_y < height)
{