# HG changeset patch # User Eli Zaretskii # Date 976917628 0 # Node ID 1012790a4a9c1dcc4739bcff3af539093767bd76 # Parent 0a6636fdd569c0b49d56040bd0cfb4548eb9f05e (Info-forward-node): If the node has an Info-header-line, widen the buffer before searching for "next:" and "up:" pointers, and set the search limit to stay in the current node. diff -r 0a6636fdd569 -r 1012790a4a9c lisp/info.el --- a/lisp/info.el Fri Dec 15 17:14:56 2000 +0000 +++ b/lisp/info.el Fri Dec 15 22:00:28 2000 +0000 @@ -1521,10 +1521,28 @@ (not (string-match "\\" Info-current-node))) (Info-goto-node (Info-extract-menu-counting 1)) t) - ((save-excursion (search-backward "next:" nil t)) + ((save-excursion + (save-restriction + (let (limit) + (when Info-header-line + (goto-char (point-min)) + (widen) + (forward-line -1) + (setq limit (point)) + (forward-line 1)) + (search-backward "next:" limit t)))) (Info-next) t) - ((and (save-excursion (search-backward "up:" nil t)) + ((and (save-excursion + (save-restriction + (let (limit) + (when Info-header-line + (goto-char (point-min)) + (widen) + (forward-line -1) + (setq limit (point)) + (forward-line 1)) + (search-backward "up:" limit t)))) ;; Use string-equal, not equal, to ignore text props. (not (string-equal (downcase (Info-extract-pointer "up")) "top")))