8

Suppose, we have this org file:

* Header1
** Header1-1
** Header1-2

* Header2

   1. Item 1

      1. Item 1-1
      2. Item 1-2

   2. Item 2

When I open it by default it looks like this:

* Header1...
* Header2...

Unordered items are collapsed. But when I open Header2, all the elements of the ordered list items are visible, so I see this:

* Header2

   1. Item 1

      1. Item 1-1
      2. Item 1-2

   2. Item 2

I can cycle visibility by moving the cursor to Item 1 and clicking <tab>. Is it possible to make the ordered lists collapsed by default?

0

1 Answer 1

7

That is not specific only to ordered lists. This behaviour is related to plain lists (ordered, unordered, description) in general.

For more details, see the variable org-cycle-include-plain-lists. If this variable is set to integrate, plain list items will be treated like low-level headlines.

To the point:

(setq org-cycle-include-plain-lists 'integrate)

should fix your problem for all org files (if I understand your issue correctly).

If you want more granular control then you can also set this per directory, file, etc.

Also FWIW - items belonging to the same plain list must have the same indentation on the first line.

1
  • The integrate setting can lead to strange effects when switching visibility to children - best read the doc string associated with the 'org-cycle-include-plain-lists' variable.
    – user16762
    Oct 9, 2019 at 9:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.