From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3939 invoked by alias); 16 Sep 2011 21:07:28 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 16375 Received: (qmail 7748 invoked from network); 16 Sep 2011 21:07:27 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 Received-SPF: neutral (ns1.primenet.com.au: 74.125.82.43 is neither permitted nor denied by SPF record at ntlworld.com) X-ProxyUser-IP: 81.97.71.129 Date: Fri, 16 Sep 2011 22:07:16 +0100 From: Peter Stephenson To: zsh-users@zsh.org Subject: Re: Completion lists Message-ID: <20110916220716.57cfd0f4@pws-pc.ntlworld.com> In-Reply-To: <20110916220412.44f3191c@pws-pc.ntlworld.com> References: <110913074320.ZM14249@torch.brasslantern.com> <110913104008.ZM14525@torch.brasslantern.com> <20110916220412.44f3191c@pws-pc.ntlworld.com> X-Mailer: Claws Mail 3.7.9 (GTK+ 2.24.4; x86_64-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Or even this? Index: Src/Zle/complist.c =================================================================== RCS file: /cvsroot/zsh/zsh/Src/Zle/complist.c,v retrieving revision 1.127 diff -p -u -r1.127 complist.c --- Src/Zle/complist.c 19 Jun 2011 16:26:11 -0000 1.127 +++ Src/Zle/complist.c 16 Sep 2011 21:06:08 -0000 @@ -849,9 +849,9 @@ putmatchcol(char *group, char *n) { Patcol pc; - nrefs = MAX_POS - 1; + for (pc = mcolors.pats; pc; pc = pc->next) { + nrefs = MAX_POS - 1; - for (pc = mcolors.pats; pc; pc = pc->next) if ((!pc->prog || !group || pattry(pc->prog, group)) && pattryrefs(pc->pat, n, -1, -1, 0, &nrefs, begpos, endpos)) { if (pc->cols[1]) { @@ -863,6 +863,7 @@ putmatchcol(char *group, char *n) return 0; } + } zcputs(group, COL_NO); @@ -880,9 +881,9 @@ putfilecol(char *group, char *filename, Patcol pc; int len; - nrefs = MAX_POS - 1; + for (pc = mcolors.pats; pc; pc = pc->next) { + nrefs = MAX_POS - 1; - for (pc = mcolors.pats; pc; pc = pc->next) if ((!pc->prog || !group || pattry(pc->prog, group)) && pattryrefs(pc->pat, filename, -1, -1, 0, &nrefs, begpos, endpos)) { if (pc->cols[1]) { @@ -894,6 +895,7 @@ putfilecol(char *group, char *filename, return 0; } + } if (special != -1) { colour = special; -- Peter Stephenson Web page now at http://homepage.ntlworld.com/p.w.stephenson/