Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/i386/isa allow default colours to be overridden by



details:   https://anonhg.NetBSD.org/src/rev/a597137b2c70
branches:  trunk
changeset: 525646:a597137b2c70
user:      lukem <lukem%NetBSD.org@localhost>
date:      Sun Apr 14 14:20:33 2002 +0000

description:
allow default colours to be overridden by
        PCCONS_DEFAULT_FG PCCONS_DEFAULT_SO_FG
        PCCONS_DEFAULT_BG PCCONS_DEFAULT_SO_BG

diffstat:

 sys/arch/i386/isa/pccons.c |  25 ++++++++++++++++++++-----
 1 files changed, 20 insertions(+), 5 deletions(-)

diffs (64 lines):

diff -r 83ec06bcc8a3 -r a597137b2c70 sys/arch/i386/isa/pccons.c
--- a/sys/arch/i386/isa/pccons.c        Sun Apr 14 14:20:05 2002 +0000
+++ b/sys/arch/i386/isa/pccons.c        Sun Apr 14 14:20:33 2002 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: pccons.c,v 1.152 2002/03/17 19:40:42 atatat Exp $      */
+/*     $NetBSD: pccons.c,v 1.153 2002/04/14 14:20:33 lukem Exp $       */
 
 /*-
  * Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -83,7 +83,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pccons.c,v 1.152 2002/03/17 19:40:42 atatat Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pccons.c,v 1.153 2002/04/14 14:20:33 lukem Exp $");
 
 #include "opt_ddb.h"
 #include "opt_xserver.h"
@@ -1243,6 +1243,20 @@
        return (0);
 }
 
+#ifndef        PCCONS_DEFAULT_FG
+#define        PCCONS_DEFAULT_FG       FG_LIGHTGREY
+#endif
+#ifndef        PCCONS_DEFAULT_SO_FG
+#define        PCCONS_DEFAULT_SO_FG    FG_YELLOW
+#endif
+
+#ifndef        PCCONS_DEFAULT_BG
+#define        PCCONS_DEFAULT_BG       BG_BLACK
+#endif
+#ifndef        PCCONS_DEFAULT_SO_BG
+#define        PCCONS_DEFAULT_SO_BG    BG_BLACK
+#endif
+
 void
 pcinit()
 {
@@ -1282,12 +1296,12 @@
        vs.ncol = COL;
        vs.nrow = ROW;
        vs.nchr = COL * ROW;
-       vs.at = FG_LIGHTGREY | BG_BLACK;
 
+       vs.at = PCCONS_DEFAULT_FG | PCCONS_DEFAULT_BG;
        if (vs.color == 0)
                vs.so_at = FG_BLACK | BG_LIGHTGREY;
        else
-               vs.so_at = FG_YELLOW | BG_BLACK;
+               vs.so_at = PCCONS_DEFAULT_SO_FG | PCCONS_DEFAULT_SO_BG;
 
        fillw((vs.at << 8) | ' ', crtat, vs.nchr - cursorat);
 }
@@ -1668,7 +1682,8 @@
                                case 'x': /* set attributes */
                                        switch (vs.cx) {
                                        case 0:
-                                               vs.at = FG_LIGHTGREY | BG_BLACK;
+                                               vs.at = PCCONS_DEFAULT_FG |
+                                                   PCCONS_DEFAULT_BG;
                                                break;
                                        case 1:
                                                /* ansi background */



Home | Main Index | Thread Index | Old Index