comparison lisp/simple.el @ 38833:5ddaed302dc3

(line-move): Pass an ESCAPE-FROM-EDGE argument of t when calling `constrain-to-field', to avoid problems with comint prompts.
author Miles Bader <miles@gnu.org>
date Thu, 16 Aug 2001 07:40:32 +0000
parents 08dafe901c44
children ba7523a60edc
comparison
equal deleted inserted replaced
38832:ce6b6f1fd86f 38833:5ddaed302dc3
2588 ;; LINE-BEG and LINE-END are the beginning and end of the line. 2588 ;; LINE-BEG and LINE-END are the beginning and end of the line.
2589 ;; Move there in just one step, from our starting position, 2589 ;; Move there in just one step, from our starting position,
2590 ;; with intangibility and point-motion hooks enabled this time. 2590 ;; with intangibility and point-motion hooks enabled this time.
2591 (goto-char opoint) 2591 (goto-char opoint)
2592 (setq inhibit-point-motion-hooks nil) 2592 (setq inhibit-point-motion-hooks nil)
2593 (goto-char (constrain-to-field new opoint nil t 2593 (goto-char
2594 'inhibit-line-move-field-capture)) 2594 (constrain-to-field new opoint t t 'inhibit-line-move-field-capture))
2595 ;; If intangibility processing moved us to a different line, 2595 ;; If intangibility processing moved us to a different line,
2596 ;; readjust the horizontal position within the line we ended up at. 2596 ;; readjust the horizontal position within the line we ended up at.
2597 (when (or (< (point) line-beg) (> (point) line-end)) 2597 (when (or (< (point) line-beg) (> (point) line-end))
2598 (setq new (point)) 2598 (setq new (point))
2599 (setq inhibit-point-motion-hooks t) 2599 (setq inhibit-point-motion-hooks t)
2604 (move-to-column (or goal-column temporary-goal-column))) 2604 (move-to-column (or goal-column temporary-goal-column)))
2605 (if (<= (point) line-end) 2605 (if (<= (point) line-end)
2606 (setq new (point))) 2606 (setq new (point)))
2607 (goto-char (point-min)) 2607 (goto-char (point-min))
2608 (setq inhibit-point-motion-hooks nil) 2608 (setq inhibit-point-motion-hooks nil)
2609 (goto-char (constrain-to-field new opoint nil t 2609 (goto-char
2610 'inhibit-line-move-field-capture)) 2610 (constrain-to-field new opoint t t 'inhibit-line-move-field-capture))
2611 ))) 2611 )))
2612 nil) 2612 nil)
2613 2613
2614 ;;; Many people have said they rarely use this feature, and often type 2614 ;;; Many people have said they rarely use this feature, and often type
2615 ;;; it by accident. Maybe it shouldn't even be on a key. 2615 ;;; it by accident. Maybe it shouldn't even be on a key.