From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8081 invoked from network); 29 May 2000 08:47:19 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 29 May 2000 08:47:19 -0000 Received: (qmail 12053 invoked by alias); 29 May 2000 08:47:12 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 11628 Received: (qmail 12030 invoked from network); 29 May 2000 08:47:10 -0000 From: "Bart Schaefer" Message-Id: <1000529084659.ZM28981@candle.brasslantern.com> Date: Mon, 29 May 2000 08:46:59 +0000 X-Mailer: Z-Mail (5.0.0 30July97) To: zsh-workers@sunsite.auc.dk Subject: Widget oddity with accept-line MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii I just noticed the following, by accident: function fiddle() { zle accept-line BUFFER='echo Can you see this\?' } bindey ^X^J fiddle zsh% echo Now you see me ... Can you see this? zsh% This results because accept-line is implemented simply by setting a flag. You can go on doing anything you like after accept-line; the only thing you can't do (except by send-break) is prevent the final value of $BUFFER from being executed. Also, accept-and-hold is the same as `print -z "$BUFFER"; zle accept-line' so one can do strange things like faddle() { zle accept-and-hold zle send-break } which amounts to being an expensive way to ring the bell, reprint the line, and move the cursor to the end. -- Bart Schaefer Brass Lantern Enterprises http://www.well.com/user/barts http://www.brasslantern.com Zsh: http://www.zsh.org | PHPerl Project: http://phperl.sourceforge.net