# HG changeset patch # User Richard M. Stallman # Date 718069946 0 # Node ID aa286e6e7bec2ee4819abeae80645f24c9194165 # Parent 2660a70538363bdb32352a1a773d631fe8015cb1 (Info-follow-nearest-node): Handle line breaks after *note. Fix interactive spec. Doc fix. Put on mouse-3. diff -r 2660a7053836 -r aa286e6e7bec lisp/info.el --- a/lisp/info.el Fri Oct 02 23:43:16 1992 +0000 +++ b/lisp/info.el Fri Oct 02 23:52:26 1992 +0000 @@ -827,9 +827,10 @@ (error "No %s around position %d" errorstring pos)))))) (defun Info-follow-nearest-node (click) - "\\Follow a node reference near point. Like \\[Info-menu], \\Info-follow-reference], \\[Info-next], \\[Info-previous] or \\Info-up] command. + "\\Follow a node reference near point. +Like \\[Info-menu], \\[Info-follow-reference], \\[Info-next], \\[Info-prev] or \\[Info-up] command, depending on where you click. At end of the node's text, moves to the next node." - (interactive "K") + (interactive "e") (let* ((relative-coordinates (coordinates-in-window-p (mouse-coords click) (selected-window))) (rel-x (car relative-coordinates)) @@ -838,7 +839,7 @@ (move-to-column rel-x)) (let (node) (cond - ((setq node (Info-get-token (point) "\\*note " "\\*note \\([^:]*\\):" t)) + ((setq node (Info-get-token (point) "\\*note[ \n]" "\\*note[ \n]\\([^:]*\\):" t)) (Info-follow-reference node)) ((setq node (Info-get-token (point) "\\* " "\\* \\([^:]*\\)::" t)) (Info-goto-node node)) @@ -894,6 +895,7 @@ (define-key Info-mode-map "s" 'Info-search) (define-key Info-mode-map "u" 'Info-up) (define-key Info-mode-map "\177" 'Info-scroll-down) + (define-key Info-mode-map [mouse-3] 'Info-follow-nearest-node) ) ;; Info mode is suitable only for specially formatted data.