diff options
author | Richard M. Stallman <rms@gnu.org> | 1994-02-08 23:50:09 +0000 |
---|---|---|
committer | Richard M. Stallman <rms@gnu.org> | 1994-02-08 23:50:09 +0000 |
commit | 3fa26c50017933e3104e965999b5423c038a4e39 (patch) | |
tree | 13d35a853969b5abfd6fea4f96da36a2e21115d4 | |
parent | 9ed4d64fd35fdcb7f177947df309c5a51ae13402 (diff) | |
download | emacs-3fa26c50017933e3104e965999b5423c038a4e39.tar.gz |
(show-children): Don't narrow to (1+ (point-max)) when
exposing the last level-n header in the buffer.
-rw-r--r-- | lisp/textmodes/ooutline.el | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lisp/textmodes/ooutline.el b/lisp/textmodes/ooutline.el index efd49c9f41a..7d21c98ea88 100644 --- a/lisp/textmodes/ooutline.el +++ b/lisp/textmodes/ooutline.el @@ -2,6 +2,10 @@ ;; Copyright (C) 1986, 1993 Free Software Foundation, Inc. +;; 7-Feb-94 Kevin Broadey +;; Fix show-children so it doesn't try to narrow to (1+ (point-max)) when +;; exposing the last level-n header in the buffer. +;; ;; Maintainer: FSF ;; This file is part of GNU Emacs. @@ -384,7 +388,8 @@ Default is enough to cause the following heading to appear." (beginning-of-line) (setq level (+ level (funcall outline-level))) (narrow-to-region (point) - (progn (outline-end-of-subtree) (1+ (point)))) + (progn (outline-end-of-subtree) + (if (eobp) (point-max) (1+ (point))))) (goto-char (point-min)) (while (and (not (eobp)) (progn |