use latest big cty.dat
[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 #
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 # 7 - RED, BLUE
21 # 8 - BROWN, BLUE
22 # 9 - GREEN, BLUE
23 # 10 - CYAN, BLUE
24 # 11 - BLUE, RED
25 # 12 - MAGENTA, BLUE
26 # 13 - BROWN, GREEN
27 # 14 - RED, GREEN
28
29 # You can or these with A_BOLD and or A_REVERSE for a different effect
30 #
31
32 package main;
33
34 use vars qw($maxkhist $maxshist $foreground     $background $mycallcolor @colors );
35 use Curses;
36
37 $maxkhist = 100;
38 $maxshist = 500;
39 if ($ENV{'TERM'} =~ /(xterm|ansi)/) {
40 #       $ENV{'TERM'} = 'color_xterm';
41         $foreground = COLOR_BLACK();
42         $background = COLOR_WHITE();
43         $mycallcolor = COLOR_PAIR(1);
44         @colors = (
45                    [ '^DX de [\-A-Z0-9]+:\s+([57][01]\d\d\d\.|\d\d\d\d\d\d+.)', COLOR_PAIR(1) ],
46                    [ '^DX', COLOR_PAIR(5) ],
47                    [ '^To', COLOR_PAIR(3) ],
48                    [ '^(?:WWV|WCY)', COLOR_PAIR(4) ],
49                    [ '^[-A-Z0-9]+ de [-A-Z0-9]+ \d\d-\w\w\w-\d\d\d\d \d\d\d\dZ', COLOR_PAIR(0) ],
50                    [ '^[-A-Z0-9]+ de [-A-Z0-9]+ ', COLOR_PAIR(6) ],
51                    [ '^WX', COLOR_PAIR(3) ],
52                    [ '^(User|Node|Buddy)\b', COLOR_PAIR(8) ],
53                    [ '^New mail', A_BOLD|COLOR_PAIR(5) ],
54                     
55                    );
56 }
57 if ($ENV{'TERM'} =~ /(console|linux)/) {
58         $foreground = COLOR_WHITE();
59         $background = COLOR_BLACK();
60         $mycallcolor = COLOR_PAIR(1);
61         @colors = (
62                    [ '^DX de [\-A-Z0-9]+:\s+([57][01]\d\d\d\.|\d\d\d\d\d\d+.)', COLOR_PAIR(1) ],
63                    [ '^DX', COLOR_PAIR(4) ],
64                    [ '^To', COLOR_PAIR(3) ],
65                    [ '^(?:WWV|WCY)', COLOR_PAIR(5) ],
66                    [ '^[-A-Z0-9]+ de [-A-Z0-9]+ \d\d-\w\w\w-\d\d\d\d \d\d\d\dZ', COLOR_PAIR(0) ],
67                    [ '^[-A-Z0-9]+ de [-A-Z0-9]+ ', COLOR_PAIR(6) ],
68                    [ '^WX', COLOR_PAIR(3) ],
69                    [ '^(User|Node)\b', A_BOLD|COLOR_PAIR(8) ],
70                    [ '^New mail', A_BOLD|COLOR_PAIR(5) ],
71                    );
72 }
73
74
75 1;