summaryrefslogtreecommitdiff
path: root/Build/source/texk/web2c/vftovp.ch
diff options
context:
space:
mode:
authorPeter Breitenlohner <peb@mppmu.mpg.de>2009-11-10 10:27:09 +0000
committerPeter Breitenlohner <peb@mppmu.mpg.de>2009-11-10 10:27:09 +0000
commit5e8e9500102800e68c9e7fcac9e85c1668b71a36 (patch)
tree81d79ac70ffbb127e8063f18c8f55475ca169ee1 /Build/source/texk/web2c/vftovp.ch
parente6a9c88ada2f11dd61e4c4e39dff84944bed5787 (diff)
towards TL2010: texk/web2c
git-svn-id: svn://tug.org/texlive/trunk@15964 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/web2c/vftovp.ch')
-rw-r--r--Build/source/texk/web2c/vftovp.ch113
1 files changed, 65 insertions, 48 deletions
diff --git a/Build/source/texk/web2c/vftovp.ch b/Build/source/texk/web2c/vftovp.ch
index 4cbd04bf65a..44d36c1a62f 100644
--- a/Build/source/texk/web2c/vftovp.ch
+++ b/Build/source/texk/web2c/vftovp.ch
@@ -282,10 +282,10 @@ cur_name[r] := 0; {Append null byte since this is C.}
@!MBL_string,@!RI_string,@!RCE_string:packed array [1..3] of char;
{handy string constants for |face| codes}
@y
-@!ASCII_04,@!ASCII_10,@!ASCII_14: c_string;
+@!ASCII_04,@!ASCII_10,@!ASCII_14: const_c_string;
{strings for output in the user's external character set}
@!xchr:packed array [0..255] of char;
-@!MBL_string,@!RI_string,@!RCE_string: c_string;
+@!MBL_string,@!RI_string,@!RCE_string: const_c_string;
{handy string constants for |face| codes}
@z
@@ -347,7 +347,7 @@ f:=((tfm[k+1] mod 16)*@'400+tfm[k+2])*@'400+tfm[k+3];
f:=((tfm[k+1] mod 16)*intcast(@'400)+tfm[k+2])*@'400+tfm[k+3];
@z
-% [100] No progress reports unless verbose.
+% [101] No progress reports unless verbose.
@x
incr(chars_on_line);
end;
@@ -420,31 +420,11 @@ lig_f:=lig_z[h];
@x [124] Some cc's can't handle 136 case labels.
begin o:=vf[vf_ptr]; incr(vf_ptr);
case o of
- @<Cases of \.{DVI} instructions that can appear in character packets@>@;
@y
begin o:=vf[vf_ptr]; incr(vf_ptr);
- if ((o<=set_char_0+127))or
- ((o>=set1)and(o<=set1+3))or((o>=put1)and(o<=put1+3)) then
-begin if o>=set1 then
- if o>=put1 then c:=get_bytes(o-put1+1,false)
- else c:=get_bytes(o-set1+1,false)
- else c:=o;
- if f=font_ptr then
- bad_vf('Character ',c:1,' in undeclared font will be ignored')
-@.Character...will be ignored@>
- else begin vf[font_start[f+1]-1]:=c; {store |c| in the ``hole'' we left}
- k:=font_chars[f];@+while vf[k]<>c do incr(k);
- if k=font_start[f+1]-1 then
- bad_vf('Character ',c:1,' in font ',f:1,' will be ignored')
- else begin if o>=put1 then out('(PUSH)');
- left; out('SETCHAR'); out_char(c);
- if o>=put1 then out(')(POP');
- right;
- end;
- end;
- end
+ if (o<=set1+3)or((o>=put1)and(o<=put1+3)) then
+ @<Special cases of \.{DVI} instructions to typeset characters@>@;
else case o of
- @<Cases of \.{DVI} instructions that can appear in character packets@>
@z
@x [125] `signed' is a reserved word in ANSI C.
@@ -460,48 +440,85 @@ begin if o>=set1 then
begin print_ln('Stack overflow!'); uexit(1);
@z
-@x [129] This code moved outside the case statement
+@x [129] This block of code moved outside the case statement.
@ Before we typeset a character we make sure that it exists.
@<Cases...@>=
sixty_four_cases(set_char_0),sixty_four_cases(set_char_0+64),
four_cases(set1),four_cases(put1):begin if o>=set1 then
+@y
+@ Before we typeset a character we make sure that it exists.
+
+@<Special cases...@>=
+begin if o>=set1 then
+@z
+
+@x [129] Bugfix.
if o>=put1 then c:=get_bytes(o-put1+1,false)
else c:=get_bytes(o-set1+1,false)
else c:=o;
if f=font_ptr then
- bad_vf('Character ',c:1,' in undeclared font will be ignored')
-@.Character...will be ignored@>
- else begin vf[font_start[f+1]-1]:=c; {store |c| in the ``hole'' we left}
- k:=font_chars[f];@+while vf[k]<>c do incr(k);
- if k=font_start[f+1]-1 then
- bad_vf('Character ',c:1,' in font ',f:1,' will be ignored')
- else begin if o>=put1 then out('(PUSH)');
- left; out('SETCHAR'); out_char(c);
- if o>=put1 then out(')(POP');
- right;
- end;
- end;
+@y
+ if o>=put1 then k:=get_bytes(o-put1+1,false)
+ else k:=get_bytes(o-set1+1,false)
+ else k:=o;
+ c:=k;
+ if (k<0)or(k>255) then
+ bad_vf('Character ',k:1,' is out of range and will be ignored')
+ else if f=font_ptr then
+@z
+
+@x [129] End of block of code moved outside the case statement.
end;
@y
-@ Before we typeset a character we make sure that it exists.
-(These cases moved outside the case statement, section 124.)
+ end
@z
-@x [134] No final newline unless verbose.
-print_ln('.');@/
+@x [132] Eliminate the |final_end| and |exit| labels.
+label final_end, exit;
@y
-if verbose then print_ln('.');@/
+@z
+@x
+vf_input:=true; return;
+final_end: vf_input:=false;
+exit: end;
+@y
+vf_input:=true;
+end;
+@z
+@x
+label final_end, exit;
+@y
+@z
+@x
+organize:=vf_input; return;
+final_end: organize:=false;
+exit: end;
+@y
+organize:=vf_input;
+end;
@z
-@x [134] Add newline to BAD VF/TFM comment.
- out('SO THE DATA HAS BEEN CHANGED!)');
+@x [134] Eliminate the |final_end| and |exit| labels.
+label final_end,exit;
@y
- out('SO THE DATA HAS BEEN CHANGED!)'); out_ln;
-@z
+@z
+@x
+do_map:=true; return;
+final_end: do_map:=false;
+exit:end;
+@y
+do_map:=true;
+end;
+@z
+@x [135] No final newline unless verbose.
+print_ln('.');@/
+@y
+if verbose then print_ln('.');@/
+@z
-@x [135] System-dependent changes.
+@x [136] System-dependent changes.
This section should be replaced, if necessary, by changes to the program
that are necessary to make \.{VFtoVP} work at a particular installation.
It is usually best to design your change file so that all changes to