From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28021 invoked from network); 22 Oct 1999 07:04:54 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 22 Oct 1999 07:04:54 -0000 Received: (qmail 1483 invoked by alias); 22 Oct 1999 06:53:24 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 8369 Received: (qmail 25634 invoked from network); 22 Oct 1999 06:40:13 -0000 Date: Fri, 22 Oct 1999 08:40:08 +0200 (MET DST) Message-Id: <199910220640.IAA01123@beta.informatik.hu-berlin.de> From: Sven Wischnowsky To: zsh-workers@sunsite.auc.dk In-reply-to: "Bart Schaefer"'s message of Thu, 21 Oct 1999 16:40:52 +0000 Subject: Re: PATCH: predict-on (Re: Completeinword and ambiguous completions) Bart Schaefer wrote: > On Oct 21, 9:10am, Sven Wischnowsky wrote: > } Subject: Re: Completeinword and ambiguous completions > } > } Bart Schaefer wrote: > } > zsh% setopt prompt > } > (feep, cursor stays on "m") > } > > } > What I'd like is, in the first of those cases, the cursor doesn't stay > } > on the "m" but rather moves to the end of the unambiguous prefix, so that > } > I can immediately start menu completion for the rest of the word. > } > } compmatchers=('' 'r:|=*') > } > } Is that good enough? > > It seems to work some, but not all, of the time. For example: > > zagzig<4> setopt promptt > > If the cursor is on the second `t' there are two possible completions > (promptsubst and promptpercent). So when the cursor is on the `m' I > expect TAB to move it to the second `t'. Instead I get a feep. Ugh. The completion code doesn't try to do that at all, right. You can try the (probably expensive): compmatchers=('r:|?=* r:|=*') of course. This works for me at least with your example. Another way would be to try completion again and again while moving the cursor. But that would even be more expensive. > Maybe the following will explain why I'm interested in this. I want to > press TAB in the middle of a predictivly-inserted line to jump ahead to > the next spot where I might want to edit. Almost-DWIM? Bye Sven -- Sven Wischnowsky wischnow@informatik.hu-berlin.de