In AUCTeX M-RET is bound to (LaTeX-insert-item) which makes a new properly indented line and inserts \item and a space after which the cursor is placed. I would like to extend this feature so that C-M-RET has similar functionality but for \item[description].
What I would like is for C-M-RET to
- make a new properly indented line and insert
\item[], - place the cursor between the square brackets, and
- place the cursor one space after
\item[]as Tab is pressed.
The following function is cribbed from latex.el, and modified slightly to call the argument-prompting version
LaTeX-item-argumentinstead of just inserting the item directly.You can bind that function to any key you like:
If you want
M-C-RET, use(meta control return)instead, though it only seems to work with theAltkey, and not theEsckey (which usually behaves the same...)