From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27419 invoked from network); 1 May 2008 17:32:58 -0000 X-Spam-Checker-Version: SpamAssassin 3.2.4 (2008-01-01) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.4 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.2.4 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 1 May 2008 17:32:58 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 49311 invoked from network); 1 May 2008 17:32:51 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 1 May 2008 17:32:51 -0000 Received: (qmail 19255 invoked by alias); 1 May 2008 17:32:47 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 24901 Received: (qmail 19238 invoked from network); 1 May 2008 17:32:47 -0000 Received: from bifrost.dotsrc.org (130.225.254.106) by sunsite.dk with SMTP; 1 May 2008 17:32:47 -0000 Received: from cluster-g.mailcontrol.com (cluster-g.mailcontrol.com [85.115.41.190]) by bifrost.dotsrc.org (Postfix) with ESMTP id 9A82E80ED172 for ; Thu, 1 May 2008 19:32:42 +0200 (CEST) Received: from cameurexb01.EUROPE.ROOT.PRI ([62.189.241.200]) by rly25g.srv.mailcontrol.com (MailControl) with ESMTP id m41HWcYT008239 for ; Thu, 1 May 2008 18:32:39 +0100 Received: from news01.csr.com ([10.103.143.38]) by cameurexb01.EUROPE.ROOT.PRI with Microsoft SMTPSVC(6.0.3790.3959); Thu, 1 May 2008 18:32:38 +0100 Received: from news01.csr.com (localhost.localdomain [127.0.0.1]) by news01.csr.com (8.14.2/8.13.4) with ESMTP id m41HWcFM017764 for ; Thu, 1 May 2008 18:32:38 +0100 Received: from csr.com (pws@localhost) by news01.csr.com (8.14.2/8.14.2/Submit) with ESMTP id m41HWcCO017761 for ; Thu, 1 May 2008 18:32:38 +0100 X-Authentication-Warning: news01.csr.com: pws owned process doing -bs To: zsh-workers@sunsite.dk (Zsh hackers list) Subject: Does anyone understand TXTDIRTY? X-Mailer: MH-E 8.0.3; nmh 1.2-20070115cvs; GNU Emacs 22.1.1 Date: Thu, 01 May 2008 18:32:37 +0100 Message-ID: <17760.1209663157@csr.com> From: Peter Stephenson X-OriginalArrivalTime: 01 May 2008 17:32:38.0156 (UTC) FILETIME=[59A44CC0:01C8ABB1] X-Scanned-By: MailControl A-08-50-01 (www.mailcontrol.com) on 10.71.0.135 X-Virus-Scanned: ClamAV 0.91.2/7007/Thu May 1 17:34:23 2008 on bifrost X-Virus-Status: Clean Our terminal attributes bits have a flag TXTDIRTY set when certain operations are done that involve text attributes. I think the intention is that if the attribute has a more global effect (such as turning off too many things) we can recover by turning back on the ones that should still be on. So far so good. However, the way it's called suggests we don't need it as a flag in the string, it could be passed straight to tsetcap(). I thought perhaps if the termcap capability didn't exist, it would arrange for something to happen later. But that doesn't make sense: the change needs to happen right at that point, not later. So as far as I can tell it could simply be passed in as a flag. Partly this is prompt by the thought that the zle_refresh code needs to do something similar. I haven't quite worked out whether settextattributes() as it now exists will do the right thing. Certainly it's forerunner (essentially the same code but called less often) did, but there are now more tests in front to see if we really need to change things around. -- Peter Stephenson Software Engineer CSR PLC, Churchill House, Cambridge Business Park, Cowley Road Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070