Hi Bastien,
Thanks for that info on org-catch-invisible-edits. It wasn't clear to me as the documentation implies that it helps when you "inadvertently edit an invisible part of the buffer", but it seems that the edits have to be results of key presses (not yanks or replaces, etc).
I'm not sure how useful I would find the function. I'd like a way to stop any edits (including yanks etc.) on invisible parts of a buffer.
I experimented with org-catch-invisible-edits by typing and deleting characters in folded sections of a simple org file. It seem to work well if the insertions or deletions occur at one hidden level down. In this case it opens the folded section and shows the edit after a short delay. But if I edit or delete two hidden sections down it doesn't seem to work properly as it only open the first hidden section and so the edit, which is another level down, is not shown.
For example, for the org file below, editing the line "level 2" when both "Section 1" and "Section 2" are folded (hidden) causes only "Section 1" to be unfolded with "Section 2" still folded inside it. Thus, the edits are not visible.
* section 1
level 1
** section 2
level 2
Kind regards,
Paul