]> git.eshelyaron.com Git - emacs.git/commitdiff
(Info-forward-node): If the node has an
authorEli Zaretskii <eliz@gnu.org>
Fri, 15 Dec 2000 22:03:05 +0000 (22:03 +0000)
committerEli Zaretskii <eliz@gnu.org>
Fri, 15 Dec 2000 22:03:05 +0000 (22:03 +0000)
Info-header-line, widen the buffer before searching for "next:"
and "up:" pointers, and set the search limit to stay in the
current node.

lisp/ChangeLog
lisp/info.el

index c16ab3fba57b07a666fe7dda07eca54f32a5e25c..773fd487db977df0e9407c45a407c0511f2e0cc8 100644 (file)
@@ -1,3 +1,10 @@
+2000-12-15  Eli Zaretskii  <eliz@is.elta.co.il>
+
+       * info.el (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.
+
 2000-12-16  Miles Bader  <miles@gnu.org>
 
        * simple.el (delete-trailing-whitespace): Remove extraneous let.
index 3b2e675f7f163fade140a0c4b4e7c6f8598a6497..21e32e76a4b435bb8fbc9b0a19366e68f37342e4 100644 (file)
@@ -1521,10 +1521,28 @@ N is the digit argument used to invoke this command."
                (not (string-match "\\<index\\>" 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")))