Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 8 Apr 2014 14:20:01 GMT
From:      dfilter@FreeBSD.ORG (dfilter service)
To:        freebsd-bugs@FreeBSD.org
Subject:   Re: kern/188196: commit references a PR
Message-ID:  <201404081420.s38EK1Ae025070@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR kern/188196; it has been noted by GNATS.

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: kern/188196: commit references a PR
Date: Tue,  8 Apr 2014 14:14:31 +0000 (UTC)

 Author: ray
 Date: Tue Apr  8 14:14:25 2014
 New Revision: 264258
 URL: http://svnweb.freebsd.org/changeset/base/264258
 
 Log:
   Fix cursor color in reverse video mode.
   
   PR:		kern/188196
   Submitted by:	Claude Buisson <clbuisson@orange.fr> (original version)
   MFC after:	1 week
   Sponsored by:	The FreeBSD Foundation
 
 Modified:
   head/sys/dev/vt/vt_core.c
 
 Modified: head/sys/dev/vt/vt_core.c
 ==============================================================================
 --- head/sys/dev/vt/vt_core.c	Tue Apr  8 07:32:32 2014	(r264257)
 +++ head/sys/dev/vt/vt_core.c	Tue Apr  8 14:14:25 2014	(r264258)
 @@ -652,24 +652,26 @@ static inline void
  vt_determine_colors(term_char_t c, int cursor,
      term_color_t *fg, term_color_t *bg)
  {
 +	term_color_t tmp;
 +	int invert;
 +
 +	invert = 0;
  
  	*fg = TCHAR_FGCOLOR(c);
  	if (TCHAR_FORMAT(c) & TF_BOLD)
  		*fg = TCOLOR_LIGHT(*fg);
  	*bg = TCHAR_BGCOLOR(c);
  
 -	if (TCHAR_FORMAT(c) & TF_REVERSE) {
 -		term_color_t tmp;
 +	if (TCHAR_FORMAT(c) & TF_REVERSE)
 +		invert ^= 1;
 +	if (cursor)
 +		invert ^= 1;
  
 +	if (invert) {
  		tmp = *fg;
  		*fg = *bg;
  		*bg = tmp;
  	}
 -
 -	if (cursor) {
 -		*fg = *bg;
 -		*bg = TC_WHITE;
 -	}
  }
  
  static void
 _______________________________________________
 svn-src-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/svn-src-all
 To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201404081420.s38EK1Ae025070>