Ihor Radchenko <[email protected]> writes:

> Ihor Radchenko <[email protected]> writes:
>
>> The docstring is not accurate.
>>
>> To fix this, we can either:
>> 1. Fix the docstring and call it done
>> 2. Allow the buffer to be editable. Although, I do not fully understand
>>    why the read-only has been introduced to start with. (And I cannot
>>    find anything in the mailing list archives)
>
> Hiecaq, do you have any preference?

I looked a bit further into this and found
(org-edit-src-code
         expanded (concat "*Org-Babel Preview " (buffer-name) "[ " lang " ]*"))
in `org-babel-expand-src-block'.

There,  it is intentional that the EXPANDED code is explicitly read-only
- the buffer is intended for viewing, not editing in that scenario.
This is the only place in the Org codebase where CODE argument is used.

I thus updated the docstring.
Fixed, on main.
https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=ff848a09b


-- 
Ihor Radchenko // yantar92,
Org mode maintainer,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>

Reply via email to