emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[O] Org-edit-special and C-x C-s strange behavior


From: Leo Alekseyev
Subject: [O] Org-edit-special and C-x C-s strange behavior
Date: Wed, 11 Jan 2012 00:40:13 -0600

I often edit my org-babel code blocks via org-edit-special (C-'), in
part because I find the tabbing behavior within the code blocks to be
somewhat flaky. Inevitably, when editing the code block I will press
C-x C-s (muscle memory). This causes all sorts of annoying
consequences: the buffer with the code block gets buried, window
splitting disappears, and if I go back to the original org buffer,
find the relevant code block and try to edit again via C-', I'm faced
with a rather cryptic message "Return to existing edit buffer? [n]
will revert changes: (y or n) ".

Since C-x C-s is such a basic operation, I think it should do
something more sensible in an edit buffer (for instance, it should
save the original org document and not screw with the window
configuration).  Alternatively, it could be configured to save, and
exit the edit buffer (i.e. simulate the effect of pressing C-' and
then C-x C-s in the original org buffer).  This would go a long way to
making working with code blocks more pleasant.  From my viewpoint /
usage patterns it makes a lot of sense for an edit buffer to behave
like a version of the original org buffer narrowed to the source code
block. If there's a particular reason for the current behavior, I'd be
very curious to know it.

--Leo



reply via email to

[Prev in Thread] Current Thread [Next in Thread]