Insertion of macros with two args is screwed when a region is marked

[email protected] (Frank Küster) Wed, 23 Mar 2005 14:40:54 +0100
Newsgroups gmane.emacs.auc-tex
Message-ID <[email protected]>

Remember to cover the basics, that is, what you expected to happen and
what in fact did happen.

\documentclass{article}

\begin{document}

hallo

\end{document}

Now, with transient-mark-mode enabled, mark the word "hallo" and
insert any macro with C-c C-m that has two mandatory arguments, for
example \parbox (just enter RET for the optional arg).  You'll get:

\documentclass{article}

\begin{document}

\parbox}{hallo}{

\end{document}


Of course what I want is either

\parbox{hallo}{}

or

\parbox{}{hallo}

With multicolum, it's even more fun:

\multicolumn}{{hallo}}{


Emacs  : GNU Emacs 21.4.1 (i386-pc-linux-gnu, X toolkit, Xaw3d scroll bars)
 of 2005-03-17 on trouble, modified by Debian
Package: AUCTeX 11.55

current state:
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
(setq
 window-system 'x
 LaTeX-version "2e"
 TeX-style-path '("style/" "auto/" "/home/frank/texmf/tex/latex/style/" "/h=
ome/frank/texmf/tex/latex/auto/"
		  "/usr/share/emacs21/site-lisp/auctex/style/" "/var/lib/auctex/emacs21/")
 TeX-auto-save t
 TeX-parse-self t
 TeX-master nil
 )
--=20
Frank K=FCster
Inst. f. Biochemie der Univ. Z=FCrich
Debian Developer