# HG changeset patch # User Kim F. Storm # Date 1121250578 0 # Node ID dd6ca96701a94cac3212fd978641b58c494dc2a6 # Parent 1bfadb2c1c4c97fc60a3b490915679efbcf51420 (line-move-1): Always use vertical-motion to do the last (or only) line move to ensure some movement. Undo 2005-06-23 change--don't check for overlays. diff -r 1bfadb2c1c4c -r dd6ca96701a9 lisp/simple.el --- a/lisp/simple.el Wed Jul 13 10:29:22 2005 +0000 +++ b/lisp/simple.el Wed Jul 13 10:29:38 2005 +0000 @@ -3447,14 +3447,13 @@ (signal 'end-of-buffer nil) (setq done t))) (when (and (not done) + (> arg 1) ;; Use vertical-motion for last move (not (integerp selective-display)) (not (line-move-invisible-p (point)))) - (unless (overlays-in (max (1- pos-before) (point-min)) - (min (1+ (point)) (point-max))) - ;; We avoid vertical-motion when possible - ;; because that has to fontify. - (forward-line 1) - (setq line-done t))) + ;; We avoid vertical-motion when possible + ;; because that has to fontify. + (forward-line 1) + (setq line-done t)) (and (not done) (not line-done) ;; Otherwise move a more sophisticated way. (zerop (vertical-motion 1)) @@ -3474,12 +3473,11 @@ (signal 'beginning-of-buffer nil) (setq done t))) (when (and (not done) + (< arg -1) ;; Use vertical-motion for last move (not (integerp selective-display)) (not (line-move-invisible-p (1- (point))))) - (unless (overlays-in (max (1- (point)) (point-min)) - (min (1+ pos-before) (point-max))) - (forward-line -1) - (setq line-done t))) + (forward-line -1) + (setq line-done t)) (and (not done) (not line-done) (zerop (vertical-motion -1)) (if (not noerror)