From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21172 invoked from network); 9 Mar 2000 12:26:02 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 9 Mar 2000 12:26:02 -0000 Received: (qmail 13470 invoked by alias); 9 Mar 2000 12:25:37 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 10015 Received: (qmail 13454 invoked from network); 9 Mar 2000 12:25:36 -0000 Date: Thu, 9 Mar 2000 13:21:19 +0100 (MET) Message-Id: <200003091221.NAA25853@beta.informatik.hu-berlin.de> From: Sven Wischnowsky To: zsh-workers@sunsite.auc.dk In-reply-to: "Bart Schaefer"'s message of Sat, 4 Mar 2000 04:46:03 +0000 Subject: Re: The `zle' command and traps Bart Schaefer wrote: > Here's an odd tidbit ... `zle' from a trap handler can actually affect the > line editor, if and only if the signal happens to arrive while ZLE is > active. E.g. try > > TMOUT=2 ; TRAPALRM() { zle -R "Hi there, I'm a trap." } > > Of course if the signal arrives when ZLE is not active, this generates an > ugly warning message. I was about to add a/some test(s) for sfcontext in bin_zle() but... this is quite cool, isn't it? ;-) We had some people asking if it was possible to display the current time in the prompt and have that updated even without having new prompts displayed. Something like the above almost allows that. So, should we disallow it completely? Or make the zle builtin be quiet if zle isn't active? Make the zle special parameters accessible (read-only) in traps if zle is active? Add a way to detect if zle is active? Add a way to detect if (the shell thinks that) there is a completion list displayed below the prompt? Etc, etc? Bye Sven -- Sven Wischnowsky wischnow@informatik.hu-berlin.de