> As suggested in bug#41198, here is a patch that adds > two new options (disabled by default): Here is a better patch. It makes possible to enable outline-minor-mode in any buffer, e.g. in prog mode, when outline-minor-mode-cycle is set to non-nil. Then typing S-TAB will collapse all headings, and TAB will expand the current function body, like this: