From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Florian Lindner Newsgroups: gmane.emacs.help Subject: Re: Key binding Supersedes: Date: Mon, 25 Nov 2002 21:49:13 +0000 Organization: T-Online Sender: help-gnu-emacs-admin@gnu.org Message-ID: References: <84el9adloh.fsf@lucy.cs.uni-dortmund.de> <3DE26324.5090703@ihs.com> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit X-Trace: main.gmane.org 1038258271 4406 80.91.224.249 (25 Nov 2002 21:04:31 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Mon, 25 Nov 2002 21:04:31 +0000 (UTC) Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18GQP4-00018c-00 for ; Mon, 25 Nov 2002 22:04:26 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10) id 18GQMG-0004ou-00; Mon, 25 Nov 2002 16:01:32 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!canoe.uoregon.edu!logbridge.uoregon.edu!newsfeed.stueberl.de!newsfeed01.sul.t-online.de!newsmm00.sul.t-online.com!t-online.de!news.t-online.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 55 Original-X-Trace: news.t-online.com 1038257785 05 5724 t1UGEcASb-AoSx 021125 20:56:25 Original-X-Complaints-To: abuse@t-online.com X-Sender: 340060635977-0001@t-dialin.net User-Agent: KNode/0.7.1 Original-Xref: shelby.stanford.edu gnu.emacs.help:107443 Original-To: help-gnu-emacs@gnu.org Errors-To: help-gnu-emacs-admin@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.0.11 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.emacs.help:3995 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:3995 Kevin Rodgers wrote: > Florian Lindner wrote: > >> it's not really working. >> That's how it looks like now: >> >> (add-hook 'pascal-mode-hook >> (lambda() >> [..] >> (defun fl-execute-current-buffer () >> "Executes the compiled file" >> (interactive) >> (shell-command (file-name-sans-extension >> buffer-file-name))) >> (define-key pascal-mode-map (kbd "C-c v") >> 'fl-execute-current-buffer))) >> >> >> I've I execute this it just displays in the minibuffer: >> >> Filename: Runtime error 201 at 0x0805C0DA >> (some more hex codes) >> >> Filename is the output my program gives right before it is waiting for >> input. >> If I just execute the program in a bash shell it works ok, I can enter >> something. > > > I believe `shell-command' executes the COMMAND with standard input bound > to > /dev/null. Try `comint-run' instead. comint-run has the same problem. Scrolling down thousands of blank lines. >> A weird problem also apperas if I try to execute the program in the shell >> mode (M-x shell), it scrolling thousands of lines with withspaces down. >> Everything works on a normal shell. >> Any ideas? > > > Perhaps your program assumes that it is connected to a terminal. You > could try using `term' (instead of `comint-run' or `shell-command'). term works, Thanks. But two more questions: 1) If the programs exits and I try to close the buffer (C-c 1) emacs just says "current buffer has no process" or "minibuffer not active" I can close the buffer via the menu, but not with C-c 1 2) How can I make the term buffer split the screen and not to take the entire screen? Thanks, Florian