all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Ihor Radchenko <yantar92@gmail.com>
To: Daniel Fleischer <danflscr@gmail.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: Recent changes in org-fold regarding emphasize visibility
Date: Sat, 07 May 2022 12:22:18 +0800	[thread overview]
Message-ID: <87ilqiynt1.fsf@localhost> (raw)
In-Reply-To: <m2k0az7omr.fsf@gmail.com>

Daniel Fleischer <danflscr@gmail.com> writes:

> Ihor Radchenko <yantar92@gmail.com> writes:
>
>> Fixed on main by d2a459d25
>
> I've tried the commit. I think there are still issues. E.g. given a
> folded headline
>
>     * Introduction...|
>     * Section
>
> Inserting text at that point will do the following thing depending on
> `org-fold-catch-invisible-edits':
>
> - error : it inserts the text without unfolding; most dangerous.
> - show : unfold, insert the text without displaying it; dangerous.
> - show-and-error: unfold but inserts the text anyways.

Thanks for testing!

The problem here is that emphasis markers and links are also partially
hidden and it is a good idea to check invisible edits there.
It's just that they were ignored by org-catch-invisible-edits in the
past. But not anymore.

I afraid that it is impossible to follow the present docstring for
org-catch-invisible-edits without mixing 'error/'show-and-error with
'smart. It's perfectly fine to insert text right after trailing ]] of
the links, but, as you showed, not after folded headline contents.

Now, we have different kinds of hidden text at hand:
- folded headlines/lists
- folded drawers
- folded blocks
- folded links/emphasis

The question is what should be the logical behaviour of Org when editing
text inside or at the border of these hidden text types? How should we
interpret the values of org-catch-invisible-edits (nil error show
show-and-error smart)?

Best,
Ihor


  reply	other threads:[~2022-05-07  4:22 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-04 13:07 Recent changes in org-fold regarding emphasize visibility Daniel Fleischer
2022-05-04 14:43 ` Ihor Radchenko
2022-05-05 19:42   ` Daniel Fleischer
2022-05-07  4:22     ` Ihor Radchenko [this message]
2022-05-07  6:57       ` Daniel Fleischer
2022-05-08  9:53         ` Ihor Radchenko
2022-05-08 14:28           ` Daniel Fleischer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87ilqiynt1.fsf@localhost \
    --to=yantar92@gmail.com \
    --cc=danflscr@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.