Warning: The font names and areas are handled inconsistently wrt TeX. @x @d random_reading==true {should we skip around in the file?} @d othercases == others: {default for cases not listed explicitly} @d endcases == @+end {follows the default case in an extended |case| statement} @f othercases == else @f endcases == end @y @d random_reading==false {should we skip around in the file?} @d othercases == others: {default for cases not listed explicitly} @d endcases == @+end {follows the default case in an extended |case| statement} @f othercases == else @f endcases == end @= @{@&$C-,A+,D-,Z-@} {no range checking, arithmetic overflow check, no debug overhead, don't initialize to zero } @z @x @p program DVI_type(@!dvi_file,@!output); @y @p @@/ program DVI_type(@!dvi_file,@!output); @z @x begin reset(dvi_file); @y begin reset(dvi_file,'','/B:8'); @z @x begin reset(tfm_file,cur_name); @y begin reset(tfm_file,cur_name,'/B:8'); @z @x begin update_terminal; reset(term_in); @y begin update_terminal; reset(term_in,'TTY:FOO1.BAR'); @z @x begin rewrite(term_out); {prepare the terminal for output} @y begin rewrite(term_out,'TTY:FOO2.BAR'); {prepare the terminal for output} @z @x @d default_directory_name=='TeXfonts:' {change this to the correct name} @d default_directory_name_length=9 {change this to the correct length} @y @d default_directory_name=='[120,44,tfm]' {change this to the correct name} @d default_directory_name_length=12 {change this to the correct length} @z @x @= for k:=1 to name_length do cur_name[k]:=' '; if p=0 then begin for k:=1 to default_directory_name_length do cur_name[k]:=default_directory[k]; r:=default_directory_name_length; end else r:=0; for k:=font_name[nf] to font_name[nf+1]-1 do begin incr(r); if r+4>name_length then abort('DVItype capacity exceeded (max font name length=', name_length:1,')!'); @.DVItype capacity exceeded...@> if (names[k]>="a")and(names[k]<="z") then cur_name[r]:=xchr[names[k]-@'40] else cur_name[r]:=xchr[names[k]]; end; cur_name[r+1]:='.'; cur_name[r+2]:='T'; cur_name[r+3]:='F'; cur_name[r+4]:='M' @y @= for k:=1 to name_length do cur_name[k]:=' '; r:=0; for k:=font_name[nf] to font_name[nf+1]-1 do begin incr(r); if default_directory_name_length +10>name_length then abort('DVItype capacity exceeded (max font name length=', name_length:0,')!'); @.DVItype capacity exceeded...@> if (names[k]>="a")and(names[k]<="z") then cur_name[r]:=xchr[names[k]-@'40] else cur_name[r]:=xchr[names[k]]; end; cur_name[r+1]:='.'; cur_name[r+2]:='T'; cur_name[r+3]:='F'; cur_name[r+4]:='M'; if p=0 then begin for k:=1 to default_directory_name_length do cur_name[r+4+k]:=default_directory[k]; end; @z