Mercurial > emacs
comparison src/xdisp.c @ 9218:db4473eb2265
(redisplay_window): If we set PT, and that alters a region
being displayed, call try_window again.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Sun, 02 Oct 1994 02:41:24 +0000 |
parents | 610e18fd64a9 |
children | be217af4e252 |
comparison
equal
deleted
inserted
replaced
9217:1ed75812c134 | 9218:db4473eb2265 |
---|---|
1146 if (startp < BEGV) startp = BEGV; | 1146 if (startp < BEGV) startp = BEGV; |
1147 if (startp > ZV) startp = ZV; | 1147 if (startp > ZV) startp = ZV; |
1148 try_window (window, startp); | 1148 try_window (window, startp); |
1149 if (cursor_vpos < 0) | 1149 if (cursor_vpos < 0) |
1150 { | 1150 { |
1151 /* ??? What should happen here if highlighting a region? */ | |
1152 /* If point does not appear, move point so it does appear */ | 1151 /* If point does not appear, move point so it does appear */ |
1153 pos = *compute_motion (startp, 0, | 1152 pos = *compute_motion (startp, 0, |
1154 ((EQ (window, minibuf_window) && startp == 1) | 1153 ((EQ (window, minibuf_window) && startp == 1) |
1155 ? minibuf_prompt_width : 0) | 1154 ? minibuf_prompt_width : 0) |
1156 + | 1155 + |
1166 if (current_buffer == old) | 1165 if (current_buffer == old) |
1167 lpoint = PT; | 1166 lpoint = PT; |
1168 FRAME_CURSOR_X (f) = max (0, pos.hpos) + XFASTINT (w->left); | 1167 FRAME_CURSOR_X (f) = max (0, pos.hpos) + XFASTINT (w->left); |
1169 FRAME_CURSOR_Y (f) = pos.vpos + XFASTINT (w->top); | 1168 FRAME_CURSOR_Y (f) = pos.vpos + XFASTINT (w->top); |
1170 } | 1169 } |
1170 /* If we are highlighting the region, | |
1171 then we just changed the region, so redisplay to show it. */ | |
1172 cancel_my_columns (XWINDOW (window)); | |
1173 if (!NILP (Vtransient_mark_mode) | |
1174 && !NILP (current_buffer->mark_active)) | |
1175 try_window (window, startp); | |
1171 } | 1176 } |
1172 goto done; | 1177 goto done; |
1173 } | 1178 } |
1174 | 1179 |
1175 /* Handle case where text has not changed, only point, | 1180 /* Handle case where text has not changed, only point, |