added some heristics for console/xterms
[spider.git] / perl / Console.pm
1 #
2 # These are the default variables for the console program
3 #
4 # DON'T ALTER this file, copy it to ../local and alter that
5 # instead. This file will be overwritten with new releases
6 #
7 # Copyright (c) 1999 Dirk Koopman G1TLH
8 #
9 # $Id$
10 #
11 # The colour pairs are:-
12 #
13 # 0 - $foreground, $background
14 # 1 - RED, $background
15 # 2 - BROWN, $background
16 # 3 - GREEN, $background
17 # 4 - CYAN, $background
18 # 5 - BLUE, $background
19 # 6 - MAGENTA, $background
20 #
21
22 package main;
23
24 $maxkhist = 100;
25 $maxshist = 500;
26 if ($ENV{'TERM'} =~ /xterm/) {
27         $ENV{'TERM'} = 'color_xterm';
28         $foreground = COLOR_BLACK();
29         $background = A_BOLD|COLOR_WHITE();
30 }
31 if ($ENV{'TERM'} =~ /(console|linux)/) {
32         $foreground = COLOR_WHITE();
33         $background = COLOR_BLACK();
34 }
35
36 @colors = (
37                    [ '^DX de [\-\w]+:\s+(14[45]\d\d\d|5[01]\d\d\d)', COLOR_PAIR(1) ],
38                    [ '^DX', COLOR_PAIR(2) ],
39                    [ '^To', COLOR_PAIR(3) ],
40                    [ '^WWV', COLOR_PAIR(4) ],
41                    [ '^WX', COLOR_PAIR(5) ],
42 );
43
44 1;