Commit 835766b6 authored by Richard M. Stallman's avatar Richard M. Stallman
Browse files

(redisplay_window): Set pos.bytepos along with pos.bufpos.

parent aeab5be0
......@@ -2260,7 +2260,10 @@ redisplay_window (window, just_this_one, preserve_echo_area)
/* If we scrolled to an actual line boundary,
that's different; don't ignore line boundaries. */
&& FETCH_BYTE (pos.bufpos - 1) != '\n')
pos.bufpos = PT - minibuffer_scroll_overlap;
{
pos.bufpos = PT - minibuffer_scroll_overlap;
pos.bytepos = CHAR_TO_BYTE (pos.bufpos);
}
/* Set startp here explicitly in case that helps avoid an infinite loop
in case the window-scroll-functions functions get errors. */
......@@ -2270,6 +2273,7 @@ redisplay_window (window, just_this_one, preserve_echo_area)
run_hook_with_args_2 (Qwindow_scroll_functions, window,
make_number (pos.bufpos));
pos.bufpos = marker_position (w->start);
pos.bytepos = marker_byte_position (w->start);
}
try_window (window, pos.bufpos);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment