The fill-paragraph
function isn't aware of the inline Org Mode source block syntax and is able to destroy it. For instance the following paragraph
Lorem ipsum dolor sit amet, consectetur src_emacs-lisp[:var x='adipiscing]{x} elit.
Proin nibh augue, suscipit a, scelerisque sed, lacinia in, mi.
(after invoking the fill-paragraph
) is rearranged into
Lorem ipsum dolor sit amet, consectetur src_emacs-lisp[:var
x='adipiscing]{x} elit. Proin nibh augue, suscipit a, scelerisque
sed, lacinia in, mi.
and the source block functionality is broken.
How can I prevent fill-paragraph from breaking Org Mode inline source block?
UPDATE:
I had this issue in Org Mode version 8.3.4. The problem does not apply to the Org Mode version 9.0.3 (at the time of writing this, 9.0.3 is the latest version available on Melpa).
Beware of this issue when updating to 9.X version!