aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChong Yidong2009-02-07 05:51:27 +0000
committerChong Yidong2009-02-07 05:51:27 +0000
commitb6d79b2f069eac96fe9f45ef084975a4d6d3bea8 (patch)
tree2437ac7f8c7a7831f255b382b4ca3b82fa8ee757
parentb352f3398a221427df5f5174aed23fcef175c1b5 (diff)
downloademacs-b6d79b2f069eac96fe9f45ef084975a4d6d3bea8.tar.gz
emacs-b6d79b2f069eac96fe9f45ef084975a4d6d3bea8.zip
(line-move-visual): Handle overflow-newline-into-fringe.
-rw-r--r--lisp/simple.el9
1 files changed, 6 insertions, 3 deletions
diff --git a/lisp/simple.el b/lisp/simple.el
index 8410d625fc3..950d7f0730d 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -4035,9 +4035,12 @@ into account variable-width characters and line continuation."
4035 (or (memq last-command '(next-line previous-line)) 4035 (or (memq last-command '(next-line previous-line))
4036 ;; In case we're called from some other command. 4036 ;; In case we're called from some other command.
4037 (eq last-command this-command))) 4037 (eq last-command this-command)))
4038 (let ((x (car (nth 2 (posn-at-point))))) 4038 (let ((posn (posn-at-point))
4039 (when x 4039 x)
4040 (setq temporary-goal-column (/ (float x) (frame-char-width)))))) 4040 (cond ((eq (nth 1 posn) 'right-fringe) ; overflow-newline-into-fringe
4041 (setq temporary-goal-column (- (window-width) 1)))
4042 ((setq x (car (nth 2 posn)))
4043 (setq temporary-goal-column (/ (float x) (frame-char-width)))))))
4041 (or (= (vertical-motion 4044 (or (= (vertical-motion
4042 (cons (or goal-column (truncate temporary-goal-column)) arg)) 4045 (cons (or goal-column (truncate temporary-goal-column)) arg))
4043 arg) 4046 arg)