Mercurial > emacs
comparison src/indent.c @ 6763:51de9400bf88
(Fvertical_motion): Use window arg, not selected_window.
author | Karl Heuer <kwzh@gnu.org> |
---|---|
date | Sat, 09 Apr 1994 04:15:16 +0000 |
parents | 5877a8b11f0c |
children | d84152a9b7e5 |
comparison
equal
deleted
inserted
replaced
6762:f77de1e2b48b | 6763:51de9400bf88 |
---|---|
858 if beginning or end of buffer was reached.") | 858 if beginning or end of buffer was reached.") |
859 (lines, window) | 859 (lines, window) |
860 Lisp_Object lines, window; | 860 Lisp_Object lines, window; |
861 { | 861 { |
862 struct position pos; | 862 struct position pos; |
863 register struct window *w = XWINDOW (selected_window); | 863 register struct window *w; |
864 int width = window_internal_width (w) - 1; | |
865 | 864 |
866 CHECK_NUMBER (lines, 0); | 865 CHECK_NUMBER (lines, 0); |
867 if (! NILP (window)) | 866 if (! NILP (window)) |
868 CHECK_WINDOW (window, 0); | 867 CHECK_WINDOW (window, 0); |
869 else | 868 else |
870 XSET (window, Lisp_Window, selected_window); | 869 XSET (window, Lisp_Window, selected_window); |
871 | 870 |
872 pos = *vmotion (point, XINT (lines), width, | 871 w = XWINDOW (window); |
872 pos = *vmotion (point, XINT (lines), window_internal_width (w) - 1, | |
873 /* Not XFASTINT since perhaps could be negative */ | 873 /* Not XFASTINT since perhaps could be negative */ |
874 XINT (w->hscroll), window); | 874 XINT (w->hscroll), window); |
875 | 875 |
876 SET_PT (pos.bufpos); | 876 SET_PT (pos.bufpos); |
877 return make_number (pos.vpos); | 877 return make_number (pos.vpos); |