From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 862 invoked by alias); 23 Feb 2015 01:55:40 -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: 19898 Received: (qmail 5856 invoked from network); 23 Feb 2015 01:55:39 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=0.6 required=5.0 tests=BAYES_00,TO_NO_BRKTS_PCNT autolearn=no version=3.3.2 Date: Mon, 23 Feb 2015 02:55:37 +0100 From: Vincent Lefevre To: zsh-users@zsh.org Subject: Re: ANSI bg colour outside of prompt area Message-ID: <20150223015537.GB17402@xvii.vinc17.org> Mail-Followup-To: zsh-users@zsh.org References: <20150222132310.GA18377@wintermute> <150222111007.ZM18687@torch.brasslantern.com> <4497961424642126@web27g.yandex.ru> <150222172204.ZM19090@torch.brasslantern.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <150222172204.ZM19090@torch.brasslantern.com> X-Mailer-Info: http://www.vinc17.net/mutt/ User-Agent: Mutt/1.5.23-6424-vl-r76280 (2015-02-19) On 2015-02-22 17:22:04 -0800, Bart Schaefer wrote: > On Feb 23, 12:55am, ZyX wrote: [...] > } I mean, whether it makes sense to output \C-o to drop SO mode by > } default just like it is done currently with colors. > > Hrm. The Lock Shift feature to chose character sets is a lot less common, > the prompt code would actually have to check that the G0 capability is > present in the terminal definition, etc. I'm not personally familiar with > the terminal handling code in prompt.c ... on brief examiniation I can't > even find where it's emitting color reset and clear-screen. > > Still, there's no reason you can't put $'%{\CO%}' at the front of $PS1. > Or putting that in $PROMPT_EOL_MARK might work as well. FYI, I do something like that in my precmd function: [[ -n $TTY && -n $terminfo ]] && { echoti rmacs echoti sgr0 echoti cnorm } > $TTY 2> /dev/null -- Vincent Lefèvre - Web: 100% accessible validated (X)HTML - Blog: Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)