Subject: Re: bug#41198: 27.0.60; [PATCH] heading cycling command for outline

From: Stefan Kangas <[email-masked]>
Date: Mon, 18 May 2020 19:45:10 -0700

forcemerge 41130 41198
thanks

Yuan Fu <[email-masked]> writes:

> Add two commands that cycles a heading (like that in Org mode) in outline-mode:
>
> - outline-cycle: cycles between “hide all”, “sub headings” and “show all” state. They are called “FOLDED”, “CHILDREN”, “SUBTREE” in Org mode.
> - outline-cycle-buffer: cycles between “only top level headings”, “all headings”, “show all” states

Thanks for working on this.  I've tested your patch, and it seems to
work as advertised.

> Could this be useful?

I think it could.  I have previously sent the wishlist Bug#41130, which
I have now merged with this bug.  I have seen no objections to that
proposal, so I hope that it is uncontroversial.

In Bug#41130, I also suggest to add the same keybinding as in org-mode:
TAB and S-TAB.  Could you add such keybindings to outline-mode-map in
your patch?

I think we also need ChangeLog in the commit message, an entry in NEWS,
and updates to the manual.

> +(defun outline-cycle ()
> +  "Cycle between “hide all”, “headings only” and “show all”.
> +
> +“Hide all” means hide all subheadings and their bodies.
> +“Headings only” means show sub headings but not their bodies.
> +“Show all” means show all subheadings and their bodies."

I can't remember seeing double quotes used like that before in doc
strings.  Correct me if I'm wrong, but wouldn't we normally use
`single-quotes' for something like this?

Best regards,
Stefan Kangas