0

Recently, I started experiencing unexpected behavior when editing org-mode files.

Suppose I have two headings, with _ indicating the cursor position.

* Heading
*_
** Subheading

I want to insert a new subheading before the existing one. So I now press * to get a second asterisk. But I don't get a second *. Instead, one of the asterisks from the existing subheading on the line below disappears! Then I press * again, and now the asterisk reappears! Now I press * for a third time, and I finally get the second asterisk on the new heading that I want to insert. So I press space to give it a title, only to find that I now have four asterisks! Like this:

* Heading
**** _ 
** Subheading

I find this behavior extremely annoying and have no idea how it is supposed to be helpful or what purpose it serves. I don't think I changed anything in my setup, so it might have been enabled by an update. I want to turn it off, but I can't find the relevant variable (meaning I don't even know what to search for). Does anyone know how to turn this "feature" off?

1
  • Does it happen if you start with emacs -q? If not, there is something in your init file causing this: bisect it to figure out what's doing it. FWIW, I cannot reproduce it in Org mode 9.4.4.
    – NickD
    Mar 21 at 18:11
2

EDIT:

I found this is a known bug in org-mode. The problem is setting org-hide-emphasis-markers to t. Once it's set back to nil (the default), the problem goes away. It is because org tries to hide the strong emphasis marker, **.

I reported my finding to the org mailing list.

1
  • Yes, you are right.
    – NickD
    Mar 22 at 1:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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