Hi, The following patch adresses two problems in Tcl mode: * The Tcl prompt, "%", isn't deleted correctly, which results in multiple prompts on the same line when sending functions or the region to the inferior Tcl buffer. There are two reasons for this: 1. Due to field boundaries `beginning-of-line' doesn't move over the prompt. 2. A trailing newline is always added even if it's already present. * On ms-windows /no/ prompt is displayed. The reason is explained on : [..] on Windows, Emacs is unable to make the Tcl interpreter start in the "interactive" mode. The problem is that Tcl calls istty() to determine whether tcl_interactive should be set and whether prompts should be displayed. But the Windows version of Emacs can not make istty() return the right value so this doesn't happen and tclsh thinks it's running non-interactive. My change makes it work out-of-the-box if you're using tclsh. It doesn't fix it if you're using wish, though (which is the default in Emacs). 2006-04-18 Jesper Harder * tcl.el (tcl-eval-region): Replace multiple trailing newlines with just one. (tcl-send-string): Use (forward-line 0) rather than beginning-of-line. (tcl-send-region): Delete. (inferior-tcl): Set tcl_interactive to 1 on ms-windows.