1 /* This file is part of the GNU plotutils package. Copyright (C) 1995, 2 1996, 1997, 1998, 1999, 2000, 2005, 2008, Free Software Foundation, Inc. 3 4 The GNU plotutils package is free software. You may redistribute it 5 and/or modify it under the terms of the GNU General Public License as 6 published by the Free Software foundation; either version 2, or (at your 7 option) any later version. 8 9 The GNU plotutils package is distributed in the hope that it will be 10 useful, but WITHOUT ANY WARRANTY; without even the implied warranty of 11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 12 General Public License for more details. 13 14 You should have received a copy of the GNU General Public License along 15 with the GNU plotutils package; see the file COPYING. If not, write to 16 the Free Software Foundation, Inc., 51 Franklin St., Fifth Floor, 17 Boston, MA 02110-1301, USA. */ 18 19 /* The 16 standard colors (ANSI, ISO 6429) supported by the Tektronix mode 20 of MS-DOS Kermit. (Reportedly `color xterm' supports them too, but 21 maybe not in Tektronix emulation mode?) 22 23 It includes the 8 standard colors (vertices of the RGB cube). It also 24 includes an intermediate brightness for each of the 6 colors other than 25 black and white, and two intermediate brightnesses for white (i.e., two 26 shades of gray intermediate between black and white). The two shades of 27 gray are the only colors in the interior of the cube. */ 28 29 #include "sys-defines.h" 30 #include "extern.h" 31 32 const plColor _pl_t_kermit_stdcolors[TEK_NUM_ANSI_SYS_COLORS] = 33 { 34 {0x00, 0x00, 0x00}, /* black */ 35 {0x8b, 0x00, 0x00}, /* red4 */ 36 {0x00, 0x8b, 0x00}, /* green4 */ 37 {0x8b, 0x8b, 0x00}, /* yellow4 */ 38 {0x00, 0x00, 0x8b}, /* blue4 */ 39 {0x8b, 0x00, 0x8b}, /* magenta4 */ 40 {0x00, 0x8b, 0x8b}, /* cyan4 */ 41 {0x8b, 0x8b, 0x8b}, /* gray55 */ 42 {0x4d, 0x4d, 0x4d}, /* gray30 */ 43 {0xff, 0x00, 0x00}, /* red */ 44 {0x00, 0xff, 0x00}, /* green */ 45 {0xff, 0xff, 0x00}, /* yellow */ 46 {0x00, 0x00, 0xff}, /* blue */ 47 {0xff, 0x00, 0xff}, /* magenta */ 48 {0x00, 0xff, 0xff}, /* cyan */ 49 {0xff, 0xff, 0xff} /* white */ 50 }; 51 52 /* Ordering of these two lists of ANSI escape sequences must match the 53 above. */ 54 55 const char * const _pl_t_kermit_fgcolor_escapes[TEK_NUM_ANSI_SYS_COLORS] = 56 { 57 "\033[0;30m", /* black */ 58 "\033[0;31m", /* red4 */ 59 "\033[0;32m", /* green4 */ 60 "\033[0;33m", /* yellow4 */ 61 "\033[0;34m", /* blue4 */ 62 "\033[0;35m", /* magenta4 */ 63 "\033[0;36m", /* cyan4 */ 64 "\033[0;37m", /* gray55 */ 65 "\033[1;30m", /* gray30 */ 66 "\033[1;31m", /* red */ 67 "\033[1;32m", /* green */ 68 "\033[1;33m", /* yellow */ 69 "\033[1;34m", /* blue */ 70 "\033[1;35m", /* magenta */ 71 "\033[1;36m", /* cyan */ 72 "\033[1;37m" /* white */ 73 }; 74 75 const char * const _pl_t_kermit_bgcolor_escapes[TEK_NUM_ANSI_SYS_COLORS] = 76 { 77 "\033[0;40m", /* black */ 78 "\033[0;41m", /* red4 */ 79 "\033[0;42m", /* green4 */ 80 "\033[0;43m", /* yellow4 */ 81 "\033[0;44m", /* blue4 */ 82 "\033[0;45m", /* magenta4 */ 83 "\033[0;46m", /* cyan4 */ 84 "\033[0;47m", /* gray55 */ 85 "\033[1;40m", /* gray30 */ 86 "\033[1;41m", /* red */ 87 "\033[1;42m", /* green */ 88 "\033[1;43m", /* yellow */ 89 "\033[1;44m", /* blue */ 90 "\033[1;45m", /* magenta */ 91 "\033[1;46m", /* cyan */ 92 "\033[1;47m" /* white */ 93 }; 94