mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-15 10:30:25 -08:00
(hide-body): Don't hide lines at the top of the file
that precede the first header line.
This commit is contained in:
parent
14e32dd339
commit
00958fa2aa
1 changed files with 3 additions and 2 deletions
|
|
@ -723,7 +723,7 @@ Show the heading too, if it is currently invisible."
|
|||
(progn (outline-next-preface) (point)) nil)))
|
||||
|
||||
(defun hide-body ()
|
||||
"Hide all of buffer except headings."
|
||||
"Hide all body lines in buffer, leaving all headings visible."
|
||||
(interactive)
|
||||
(hide-region-body (point-min) (point-max)))
|
||||
|
||||
|
|
@ -738,7 +738,8 @@ Show the heading too, if it is currently invisible."
|
|||
(narrow-to-region start end)
|
||||
(goto-char (point-min))
|
||||
(if (outline-on-heading-p)
|
||||
(outline-end-of-heading))
|
||||
(outline-end-of-heading)
|
||||
(outline-next-preface))
|
||||
(while (not (eobp))
|
||||
(outline-flag-region (point)
|
||||
(progn (outline-next-preface) (point)) t)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue