delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2005/10/19/20:35:59

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Date: Wed, 19 Oct 2005 20:35:27 -0400 (EDT)
From: Igor Pechtchanski <pechtcha AT cs DOT nyu DOT edu>
Reply-To: cygwin AT cygwin DOT com
To: Robert Bram <Robert DOT Bram AT colesmyer DOT com DOT au>
cc: cygwin AT cygwin DOT com
Subject: RE: exiting vim changes background colour of console
In-Reply-To: <88ACCA0E0A7A914DAFBA3918021605D24E3FD4@WPEXCH08.colesmyer.ad.cmltd.net.au>
Message-ID: <Pine.GSO.4.63.0510192020400.16245@slinky.cs.nyu.edu>
References: <88ACCA0E0A7A914DAFBA3918021605D24E3FD4 AT WPEXCH08 DOT colesmyer DOT ad DOT cmltd DOT net DOT au>
MIME-Version: 1.0

On Thu, 20 Oct 2005, Robert Bram wrote:

> Hi Igor,
>
> <snip>
> > > My PS1 variable is:
> > > \e[47m\n\s\v User \u on host \h in dir \w\n\d \@>\e[0;30m
> > >
> > > bash2.05b User rbram on host cml035835 in dir /cygdrive/c/eTech/eForms2
> > > Thu Oct 20 07:16 AM> echo $PS1
> > > \e[47m\n\s\v User \u on host \h in dir \w\n\d \@>\e[0;30m
> >
> > Note that the end of your PS1 resets the color to "black background"...
> > Removing that '\e[0;30m' should fix your problem, unless you want your
> > window background to be something other than grey, in which case you'll
> > have to put in a background change to whatever your window background is.
> >
> > FWIW, you might also want to put \[ and \] around the non-printable
> > characters in PS1, to help bash calculate the prompt length better, e.g.,
> >
> > export PS1='\[\e[47m\]\n\s\v User \u on host \h in dir \w\n\d \@>'
>
> Ok, here is part of my .bash_profile now:
> blackOnLightGrey='\[\e[47m\]'
> blue='\[\e[1;34m\]'
> red='\[\e[1;31m\]'
> blackOnWhite='\[\e[0;0;37;30m\]'
> # export PS1="${blackOnLightGrey}\n\s\v User \u on host \h in dir \w\n\d \@> "
> export PS1="${blackOnLightGrey}\n\s\v User \u on host \h in dir \w\n\d \@>\e[0m "
> # export PS1="${blackOnLightGrey}\n\s\v User \u on host \h in dir \w\n\d \@>${blackOnWhite} "
>
> None of the PS1s above fix the issue! I.e. when I open a console I see
> what I want: console with white background and black foreground, with
> the prompt rendered as black foreground on grey background, but then
> whenever I do a man, less, vim and exit, the screen get a black
> background that I can make go away by pressing "ENTER" repeatedly i.e.
> shifting the black off screen.

Huh.  I haven't been able to reproduce your exact problem, as it turns
out...  I'm afraid I've reached the limit of my knowledge on this...
Sorry.
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_		pechtcha AT cs DOT nyu DOT edu
ZZZzz /,`.-'`'    -.  ;-;;,_		igor AT watson DOT ibm DOT com
     |,4-  ) )-,_. ,\ (  `'-'		Igor Pechtchanski, Ph.D.
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

If there's any real truth it's that the entire multidimensional infinity
of the Universe is almost certainly being run by a bunch of maniacs. /DA

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019