-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathFONTTEST.C
More file actions
executable file
·75 lines (73 loc) · 1.6 KB
/
FONTTEST.C
File metadata and controls
executable file
·75 lines (73 loc) · 1.6 KB
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
68
69
70
71
72
73
74
75
#include <stdio.h>
#include <graph.h>
#include "porofont.h"
char fname[8][20] = {
"BABORE16.FNT",
"FZ.FNT",
"GRA.FNT",
"GRANAME.FNT",
"LANGDON.FNT",
"MEGATEN.FNT",
"THREE16.FNT",
"XEV.FNT"
};
main()
{
int i;
int rtn;
char buf1[30];
char buf2[30];
strcpy(buf1, " !\"#$%'()*+,-./0123456789:;<=");
strcpy(buf2, ">?@ABCDEFGHIJKLMNOPQRSTUVWXYZ");
printf("\x1b*■Taco.x氏作fontlib1画面展開ぷろぐらむ~\n\n");
for (i = 0; i < 8; i++) {
printf("'%12s' Reading ", fname[i]);
font_select(i);
rtn = font_read(fname[i], "TACOX");
if (rtn == READ_NG) {
printf(" / NG!\n");
font_unread();
return (0);
} else
printf("\n");
}
printf("\n読み込み終了。何かキーをおしてやってくれや。\n");
getch();
gstart;
for (i = 0; i < 8; i++) {
font_select(i);
mask_set(0xff, 0xff, 0xff, MASK_NORMAL);
out_text(0, i * 3, fname[i]);
switch (i) {
case 0:
mask_set(0xaa, 0xff, 0xff, MASK_NORMAL);
break;
case 1:
mask_set(0xff, 0xaa, 0xff, MASK_NORMAL);
break;
case 2:
mask_set(0xff, 0xff, 0xaa, MASK_NORMAL);
break;
case 3:
mask_set(0xaa, 0xff, 0xff, MASK_NORMAL);
break;
case 4:
mask_set(0xff, 0xaa, 0xff, MASK_NORMAL);
break;
case 5:
mask_set(0xff, 0xff, 0xaa, MASK_NORMAL);
break;
case 6:
mask_set(0xaa, 0xff, 0xff, MASK_NORMAL);
break;
case 7:
mask_set(0xff, 0xaa, 0xff, MASK_NORMAL);
break;
}
out_text(4, i * 3 + 1, buf1);
out_text(4, i * 3 + 2, buf2);
}
getch();
gstop;
font_unread();
}