4

I would like markdown-mode to treat URLs as normal text, so that I can click on them to place the cursor inside them rather than loading the page in a browser.

I tried toggling goto-address-mode, which didn't help, and I tried removing http and https from the list of Markdown Uri Types. I tried a few other things that in retrospect don't make much sense; I looked through all the variables that began with markdown- and couldn't find any that applied.
Is there a way to do this?

2
  • 4
    C-h v mouse-1-click-follows-link to learn the default behavior, and how to change it if you want to.
    – xuchunyang
    Nov 9, 2018 at 10:56
  • This comment is the answer. Please promote to an answer. Jan 22, 2023 at 18:49

3 Answers 3

3

You can place the cursor in the middle of a clickable element by doing a "long click" (i.e. press, hold for more than 0.5s, and then release).

1

If the issue is editing hidden links (see the link text and not the address):

The easy "built-in" (keyboard / not mouse) solution for editing the link, will be to move your cursor to it (using the keyboard) and type M-x markdown-toggle-url-hiding, then you can edit the address as text. Have a look at Github issue

1

You can turn it off.

Use C-h v mouse-1-click-follows-link to learn and change the default behaviour.

1
  • This answer is based on the excellent comment from @xuchunyang. While this comment was the correct answer. It was a comment, and the author did not promote it to an answer. Feb 5, 2023 at 9:12

Your Answer

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

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