From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22632 invoked from network); 15 Dec 2003 18:50:45 -0000 Received: from sunsite.dk (130.225.247.90) by ns1.primenet.com.au with SMTP; 15 Dec 2003 18:50:45 -0000 Received: (qmail 15625 invoked by alias); 15 Dec 2003 18:50:39 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 19288 Received: (qmail 15609 invoked from network); 15 Dec 2003 18:50:39 -0000 Received: from localhost (HELO sunsite.dk) (127.0.0.1) by localhost with SMTP; 15 Dec 2003 18:50:39 -0000 X-MessageWall-Score: 0 (sunsite.dk) Received: from [62.189.183.235] by sunsite.dk (MessageWall 1.0.8) with SMTP; 15 Dec 2003 18:50:38 -0000 Received: from EXCHANGE02.csr.com (unverified) by MAILSWEEPER01.csr.com (Content Technologies SMTPRS 4.3.10) with ESMTP id for ; Mon, 15 Dec 2003 18:50:21 +0000 Received: from csr.com ([192.168.144.127]) by EXCHANGE02.csr.com with Microsoft SMTPSVC(5.0.2195.5329); Mon, 15 Dec 2003 18:52:02 +0000 To: zsh-workers@sunsite.dk (Zsh hackers list) Subject: Re: PATCH: widget called when zle starts. In-reply-to: "Bart Schaefer"'s message of "Mon, 15 Dec 2003 18:43:16 GMT." <1031215184316.ZM13274@candle.brasslantern.com> Date: Mon, 15 Dec 2003 18:50:26 +0000 Message-ID: <1119.1071514226@csr.com> From: Peter Stephenson X-OriginalArrivalTime: 15 Dec 2003 18:52:02.0485 (UTC) FILETIME=[86E0F650:01C3C33C] Bart Schaefer wrote: > I think this is almost a requirement. Otherwise one is reduced to doing > things like this: > > precmd() { zle_use_cmd_mode=1 } > zle-line-init() { > ((zle_use_cmd_mode)) && zle vi-cmd-mode > zle_use_cmd_mode=0 > } I still haven't understood under what circumstances you'd be doing that. Are you demanding that sometimes when zle is started up, such as for a continuation line, you want to maintain the current keymap? That's way beyond the original idea of an initialisation widget. However, I think some sort of context is a good idea anyway. Unfortunately zle is not the most object-oriented piece of code, but it shouldn't be too hard. -- Peter Stephenson Software Engineer CSR Ltd., Science Park, Milton Road, Cambridge, CB4 0WH, UK Tel: +44 (0)1223 692070 ********************************************************************** This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the system manager. This footnote also confirms that this email message has been swept by MIMEsweeper for the presence of computer viruses. www.mimesweeper.com **********************************************************************