blob: 516925b0d9b7f38ec5b7e0588474bc151343d5fb (
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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
|
% $Id$
% Public domain. See ../pdftexdir/char-warning-pdftex.ch for info.
@x [30] If \tracinglostchars > 2, then promote full errors.
@p procedure char_warning(@!f:internal_font_number;@!c:sixteen_bits);
var @!l:0..255; {small indices or counters}
old_setting: integer; {saved value of |tracing_online|}
begin if tracing_lost_chars>0 then
begin old_setting:=tracing_online;
if eTeX_ex and(tracing_lost_chars>1) then tracing_online:=1;
begin begin_diagnostic;
print_nl("Missing character: There is no ");
@.Missing character@>
if (c<" ")or(c>"~") then begin
print_char("^"); print_char("^");
if c<64 then print_char(c+64)
else if c<128 then print_char(c-64)
else if c<256 then begin
print_lc_hex(c div 16); print_lc_hex(c mod 16); end
else begin print_char("^"); print_char("^");
print_lc_hex(c div 4096); print_lc_hex((c mod 4096) div 256);
print_lc_hex((c mod 256) div 16); print_lc_hex(c mod 16); end
end
else print_ASCII(c);
print(" in font ");
slow_print(font_name[f]); print_char("!"); end_diagnostic(false);
end;
tracing_online:=old_setting;
end;
end;
@y
@p procedure char_warning(@!f:internal_font_number;@!c:sixteen_bits);
var @!l:0..255; {small indices or counters}
old_setting: integer; {saved value of |tracing_online|}
begin if tracing_lost_chars>0 then
begin old_setting:=tracing_online;
if eTeX_ex and(tracing_lost_chars>1) then tracing_online:=1;
if tracing_lost_chars > 2 then
print_err("Missing character: There is no ")
else begin
begin_diagnostic;
print_nl("Missing character: There is no ")
end;
@.Missing character@>
if (c<" ")or(c>"~") then begin
print_char("^"); print_char("^");
if c<64 then print_char(c+64)
else if c<128 then print_char(c-64)
else if c<256 then begin
print_lc_hex(c div 16); print_lc_hex(c mod 16); end
else begin print_char("^"); print_char("^");
print_lc_hex(c div 4096); print_lc_hex((c mod 4096) div 256);
print_lc_hex((c mod 256) div 16); print_lc_hex(c mod 16); end
end
else print_ASCII(c);
if tracing_lost_chars > 2 then begin
print(" (");
print_hex(c);
print(")");
end;
print(" in font ");
slow_print(font_name[f]);
if tracing_lost_chars < 3 then print_char("!");
tracing_online:=old_setting;
if tracing_lost_chars > 2 then begin
help0;
error;
end else end_diagnostic(false);
end; {of |tracing_lost_chars>0|}
end; {of procedure}
@z
@x [30] Another warning for (u)pTeX.
@p procedure char_warning_jis(@!f:internal_font_number;@!jc:KANJI_code);
begin if tracing_lost_chars>0 then
begin begin_diagnostic;
print_nl("Character "); print_kanji(jc); print(" (");
print_hex(jc); print(") cannot be typeset in JIS-encoded JFM ");
slow_print(font_name[f]);
print_char(","); print_nl("so I use .notdef glyph instead.");
end_diagnostic(false);
end;
end;
@y
@p procedure char_warning_jis(@!f:internal_font_number;@!jc:KANJI_code);
var old_setting: integer; {saved value of |tracing_online|}
begin if tracing_lost_chars>0 then
begin old_setting:=tracing_online;
if eTeX_ex and(tracing_lost_chars>1) then tracing_online:=1;
if tracing_lost_chars > 2 then
print_err("Character ")
else begin
begin_diagnostic;
print_nl("Character ")
end;
print_kanji(jc); print(" (");
print_hex(jc); print(") cannot be typeset in JIS-encoded JFM ");
slow_print(font_name[f]);
print_char(",");
if tracing_lost_chars > 2 then
begin print_nl(" so I use .notdef glyph instead");
help0; error; end
else
begin print_nl("so I use .notdef glyph instead.");
end_diagnostic(false); end;
tracing_online:=old_setting;
end; {of |tracing_lost_chars>0|}
end; {of procedure}
@z
|