emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Convert some files from outline-mode to org-mode


From: Nicolas Goaziou
Subject: Re: Convert some files from outline-mode to org-mode
Date: Wed, 29 Apr 2020 16:17:42 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux)

Hello,

Howard Melman <address@hidden> writes:

> To be clear, it's better than just that. As I said I use it
> for code folding. As long as a programming mode sets
> outline-regexp then outline-minor-mode works with it and
> org-cycle and org-global-cycle work in those modes. I use
> S-TAB and C-TAB in emacs-lisp-mode, python-mode and othes
> all the time. 
>
> In emacs-lisp-mode:
>
>     (setq-local outline-regexp ";;;;? \\|(....")
>
> In python-mode:
>
>     (setq-local outline-regexp (python-rx (* space) (or defun decorator)))
>
> In html-mode:
>
>     (setq-local outline-regexp "<[hH]\\([1-6]\\)\\>")

I wouldn't expect `org-cycle' and `org-global-cycle' to work for any
`outline-regexp' value. If it works, good for you, but Org really
expects "\\*+ " here.

Implementing `outline-cycle' and `outline-global-cycle' may be more
future-proof.

Regards,

-- 
Nicolas Goaziou



reply via email to

[Prev in Thread] Current Thread [Next in Thread]