Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/lib/libcurses Copy all background attributes (not just colou...



details:   https://anonhg.NetBSD.org/src/rev/d990058c1475
branches:  trunk
changeset: 487771:d990058c1475
user:      jdc <jdc%NetBSD.org@localhost>
date:      Mon Jun 12 20:51:39 2000 +0000

description:
Copy all background attributes (not just colour) from win to __virtscr.

diffstat:

 lib/libcurses/refresh.c |  12 +++++++-----
 1 files changed, 7 insertions(+), 5 deletions(-)

diffs (34 lines):

diff -r 8b0b412c6f8c -r d990058c1475 lib/libcurses/refresh.c
--- a/lib/libcurses/refresh.c   Mon Jun 12 20:48:34 2000 +0000
+++ b/lib/libcurses/refresh.c   Mon Jun 12 20:51:39 2000 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: refresh.c,v 1.35 2000/05/20 15:12:15 mycroft Exp $     */
+/*     $NetBSD: refresh.c,v 1.36 2000/06/12 20:51:39 jdc Exp $ */
 
 /*
  * Copyright (c) 1981, 1993, 1994
@@ -38,7 +38,7 @@
 #if 0
 static char sccsid[] = "@(#)refresh.c  8.7 (Berkeley) 8/13/94";
 #else
-__RCSID("$NetBSD: refresh.c,v 1.35 2000/05/20 15:12:15 mycroft Exp $");
+__RCSID("$NetBSD: refresh.c,v 1.36 2000/06/12 20:51:39 jdc Exp $");
 #endif
 #endif                         /* not lint */
 
@@ -117,10 +117,12 @@
                        for (wx = 0, x_off = win->begx; wx < win->maxx &&
                            x_off < __virtscr->maxx; wx++, x_off++) {
                                vlp->line[x_off].attr = wlp->line[wx].attr;
-                               if (!(wlp->line[wx].attr & __COLOR) &&
-                                   (wlp->line[wx].battr & __COLOR))
+                               if (wlp->line[wx].attr & __COLOR)
                                        vlp->line[x_off].attr |=
-                                           wlp->line[wx].battr & __COLOR;
+                                           wlp->line[wx].battr & ~__COLOR;
+                               else
+                                       vlp->line[x_off].attr |=
+                                           wlp->line[wx].battr;
                                if (wlp->line[wx].ch == ' ' &&
                                    wlp->line[wx].bch != ' ')
                                        vlp->line[x_off].ch



Home | Main Index | Thread Index | Old Index