aboutsummaryrefslogtreecommitdiffstats
path: root/src/tacs/image.c
blob: 949b06852bc21ad823b00f92fb0f782817321715 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
#include <stdio.h>
#include <string.h>
#include "image.h"

const char *image[] = {
	"",
	"               @B(@g#@B)",
	"                @g#",
	"                #",
	"                #",
	"                #   @R_____",
	"               _@g#@R--- _._ ---__",
	"              |_____(_|_)_____|",
	"               |  @WTELEPHONE@R  |",
	"              |###############|",
	"              |###############|",
	"              |##   |   |   ##|",
	"              |## @B1@R | @B2@R | @B3@R ##|",
	"              |##___|___|___##|       @WTACS@R",
	"              |##   |   |   ##|",
	"              |## @B4@R | @B5@R | @B6@R ##|",
	"              |##___|___|___##|",
	"              |##   |   |   ##|",
	"              |## @B7@R | @B8@R | @B9@R ##|",
	"              |##___|___|___##|",
	"              |##   |   |   ##|",
	"              |## @B*@R | @B0@R | @B#@R ##|",
	"              |##___|___|___##|",
	"              |###############|",
	"              |##+---------+##|",
	"              |##+---------+##|",
	"              |###############|",
	"              @g+++++++++++++++++",
	"@W",
	NULL
};

void print_image(void)
{
	int i, j;

	for (i = 0; image[i]; i++) {
		for (j = 0; j < (int)strlen(image[i]); j++) {
			if (image[i][j] == '@') {
				j++;
				switch(image[i][j]) {
				case 'R': /* red */
					printf("\033[1;31m");
					break;
				case 'g': /* gray */
					printf("\033[0;37m");
					break;
				case 'W': /* white */
					printf("\033[1;37m");
					break;
				case 'B': /* blue */
					printf("\033[1;34m");
					break;
				}
			} else
				printf("%c", image[i][j]);
		}
		printf("\n");
	}
	printf("\033[0;39m");
}