diff options
| author | Gerd Moellmann | 2000-11-16 05:05:34 +0000 |
|---|---|---|
| committer | Gerd Moellmann | 2000-11-16 05:05:34 +0000 |
| commit | cac94de6556616a52265d2d41905df45822a7515 (patch) | |
| tree | b7444b5c02d68fdaf65926a7e13d41f85ec70e6f /src/xdisp.c | |
| parent | a288d0d1f23c3fd754edc84cfc2841be09e223ca (diff) | |
| download | emacs-cac94de6556616a52265d2d41905df45822a7515.tar.gz emacs-cac94de6556616a52265d2d41905df45822a7515.zip | |
(pos_visible_p): Handle case that we reach ZV without
knowing the line's height; use the default font's height in that
case.
Diffstat (limited to 'src/xdisp.c')
| -rw-r--r-- | src/xdisp.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/xdisp.c b/src/xdisp.c index c2ed64b1477..e75ae762687 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -995,13 +995,15 @@ pos_visible_p (w, charpos, fully, exact_mode_line_heights_p) | |||
| 995 | { | 995 | { |
| 996 | if (last_height) | 996 | if (last_height) |
| 997 | line_height = last_height; | 997 | line_height = last_height; |
| 998 | else | 998 | else if (charpos < ZV) |
| 999 | { | 999 | { |
| 1000 | move_it_by_lines (&it, 1, 1); | 1000 | move_it_by_lines (&it, 1, 1); |
| 1001 | line_height = (it.max_ascent || it.max_descent | 1001 | line_height = (it.max_ascent || it.max_descent |
| 1002 | ? it.max_ascent + it.max_descent | 1002 | ? it.max_ascent + it.max_descent |
| 1003 | : last_height); | 1003 | : last_height); |
| 1004 | } | 1004 | } |
| 1005 | else | ||
| 1006 | line_height = FONT_HEIGHT (FRAME_FONT (XFRAME (w->frame))); | ||
| 1005 | } | 1007 | } |
| 1006 | line_bottom_y = line_top_y + line_height; | 1008 | line_bottom_y = line_top_y + line_height; |
| 1007 | 1009 | ||