From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27144 invoked from network); 11 Nov 2004 18:06:24 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 11 Nov 2004 18:06:24 -0000 Received: (qmail 9179 invoked from network); 11 Nov 2004 18:06:18 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 11 Nov 2004 18:06:18 -0000 Received: (qmail 19225 invoked by alias); 11 Nov 2004 18:05:29 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 8205 Received: (qmail 19210 invoked from network); 11 Nov 2004 18:05:27 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 11 Nov 2004 18:05:27 -0000 Received: (qmail 7671 invoked from network); 11 Nov 2004 18:05:27 -0000 Received: from smtp-out4.blueyonder.co.uk (195.188.213.7) by a.mx.sunsite.dk with SMTP; 11 Nov 2004 18:05:26 -0000 Received: from sc ([82.41.214.33]) by smtp-out4.blueyonder.co.uk with Microsoft SMTPSVC(5.0.2195.6713); Thu, 11 Nov 2004 18:05:53 +0000 Date: Thu, 11 Nov 2004 18:05:05 +0000 From: Stephane Chazelas To: Zsh users list Subject: Re: [tip] mouse support Message-ID: <20041111180505.GG4451@sc> Mail-Followup-To: Zsh users list References: <20041111122011.GB4451@sc> <4483.1100184032@csr.com> <20041111162209.GC4451@sc> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.5.6i X-OriginalArrivalTime: 11 Nov 2004 18:05:53.0779 (UTC) FILETIME=[15BEF430:01C4C819] X-Spam-Checker-Version: SpamAssassin 2.63 on a.mx.sunsite.dk X-Spam-Level: * X-Spam-Status: No, hits=1.5 required=6.0 tests=RCVD_IN_SORBS autolearn=no version=2.63 X-Spam-Hits: 1.5 On Thu, Nov 11, 2004 at 09:47:02AM -0800, Bart Schaefer wrote: > On Thu, 11 Nov 2004, Stephane Chazelas wrote: > > > In that new one, I tried to address the tab/newline issue. > > It tries to calculate the length of the last line of the prompt, > > it may fail if PS1 contains %%s or %{ %{ ... %} %} or if two > > consecutive expansions of PS1 may not generate the same thing > > There's some code in Functions/Prompts/prompt_bart_setup in the function > prompt_bart_precmd that computes the width of prompt strings. It's been > specialized to expect to compute only the width of the first line of a > two-line PS1, but it shouldn't be hard to adapt. Hi Bart, we actually chose the same approach, it suffers from the same problems: zero='%([BSUbsu]|{*%})' It replaces '%%some %{%{some%}%}' with '%ome %}' instead of '%%some ' Thanks for the (%%) flag, though. -- Stéphane