Mercurial > emacs
comparison src/xdisp.c @ 65354:cc9451bcd3a0
(try_window): Remove superfluous cursor_height calculation.
Fixes crash reported by YAMAMOTO Mitsuharu.
author | Kim F. Storm <storm@cua.dk> |
---|---|
date | Wed, 07 Sep 2005 08:46:04 +0000 |
parents | 33c5395c982b |
children | 5780229616e2 |
comparison
equal
deleted
inserted
replaced
65353:67a6de075836 | 65354:cc9451bcd3a0 |
---|---|
12828 | 12828 |
12829 /* Don't let the cursor end in the scroll margins. */ | 12829 /* Don't let the cursor end in the scroll margins. */ |
12830 if (check_margins | 12830 if (check_margins |
12831 && !MINI_WINDOW_P (w)) | 12831 && !MINI_WINDOW_P (w)) |
12832 { | 12832 { |
12833 int this_scroll_margin, cursor_height; | 12833 int this_scroll_margin; |
12834 | 12834 |
12835 this_scroll_margin = max (0, scroll_margin); | 12835 this_scroll_margin = max (0, scroll_margin); |
12836 this_scroll_margin = min (this_scroll_margin, WINDOW_TOTAL_LINES (w) / 4); | 12836 this_scroll_margin = min (this_scroll_margin, WINDOW_TOTAL_LINES (w) / 4); |
12837 this_scroll_margin *= FRAME_LINE_HEIGHT (it.f); | 12837 this_scroll_margin *= FRAME_LINE_HEIGHT (it.f); |
12838 cursor_height = MATRIX_ROW (w->desired_matrix, w->cursor.vpos)->height; | |
12839 | 12838 |
12840 if ((w->cursor.y < this_scroll_margin | 12839 if ((w->cursor.y < this_scroll_margin |
12841 && CHARPOS (pos) > BEGV) | 12840 && CHARPOS (pos) > BEGV) |
12842 /* rms: considering make_cursor_line_fully_visible_p here | 12841 /* rms: considering make_cursor_line_fully_visible_p here |
12843 seems to give wrong results. We don't want to recenter | 12842 seems to give wrong results. We don't want to recenter |