all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Bug in org-insert-link?
@ 2023-09-27 15:29 Guillaume MULLER
  2023-10-05 10:18 ` Ihor Radchenko
  0 siblings, 1 reply; 9+ messages in thread
From: Guillaume MULLER @ 2023-09-27 15:29 UTC (permalink / raw)
  To: emacs-orgmode@gnu.org


[-- Attachment #1.1.1: Type: text/plain, Size: 1077 bytes --]

Hi,

Here is a situation that I often end up in:

- Open a .org file
- Type some text
- Select it
- Call org-insert-link
- Switch to another windows/desktop to find my running firefox
- Copy a URL
- Switch back to (Doom)Emacs ("window"/desktop)
- Click inside the Emacs "window" to give it focus
[Here is the problem: sometimes I forgot that I already started the org-insert-link]
- Call org-insert-link
- Paste the URL
- Validate the link creation

Then the link is inserted where I clicked last (to give focus to the Emacs "window").

Of course, the problem lies in my mistake of calling twice the org-insert-link method, but the behavior is very strange, and it took me some time to identify why my links were inserted at random places in my text.

However, wouldn't it be possible to prevent it from the beginning by forbidding me to call org-insert-link twice, i.e. making it a singleton/atomic function (I don't see a UseCase where this could be useful to be able to call it inside itself, but maybe I'm wrong)?

Thanks


-- 
Guillaume MULLER

[-- Attachment #1.1.2: OpenPGP public key --]
[-- Type: application/pgp-keys, Size: 673 bytes --]

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 236 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2023-12-05 12:27 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-09-27 15:29 Bug in org-insert-link? Guillaume MULLER
2023-10-05 10:18 ` Ihor Radchenko
2023-10-09 14:40   ` Guillaume MULLER
2023-10-10 11:25     ` Ihor Radchenko
2023-10-10 11:33       ` Guillaume MULLER
2023-10-10 11:38         ` Ihor Radchenko
2023-12-04 15:24     ` Guillaume MULLER
2023-12-04 16:13       ` Guillaume MULLER
2023-12-05 12:29         ` Ihor Radchenko

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.