Suppose I have an org-mode
buffer that contains the outline shown below, and that point is at the position indicated by the ▮ character.
* foo
** bar
*** baz
- eenie
- yabba
- dabba▮
- doo
- meenie
- minie
* frobozz
** quux
Call this particular configuration (buffer content + point position) the initial state.
If I now run org-insert-heading
(IOW, I type M-<RET>
), I get a new list item:
* foo
** bar
*** baz
- eenie
- yabba
- dabba
- ▮
- doo
- meenie
- minie
* frobozz
** quux
Now, I think of a "heading" in an org-mode
outline as a line beginning with *
's. Therefore, if I interpret the name of the command org-insert-heading
literally, I would have expected that running org-insert-heading
from the initial state would have produced the following, which I'll refer to as the desired state:
* foo
** bar
*** baz
- eenie
- yabba
- dabba
- doo
- meenie
- minie
*** ▮
* frobozz
** quux
My question is:
does the
org-mode
interface already provides a more direct way1 to achieve the desired state starting from the initial state?
(In case that the answer to this question is "no", then a distant second-best would be a way to override org-insert-heading
so that it behaves the way I think it should (i.e. always inserting a heading, namely a line starting with *
s, and thus producing the desired state from the initial state), together with a new custom command that preserves the default behavior of org-insert-heading
in the initial state. I'd appreciate any help I can get with this too.)
1 I stress that my question does not ask for any way, by hook or crook, to get to the desired state from the initial state. I realize that, if nothing else, I can always "revert to plain Emacs", so to speak: for example, I can move point as shown below
* foo
** bar
*** baz
- eenie
- yabba
- dabba
- doo
- meenie
- minie▮
* frobozz
** quux
...and then type the sequence RET***SPC, to arrive at the desired state.