{ for PRINT version 1.20 - 31-may-1986:rjr } procedure EXECDOT; var DotCommand : string[3]; Num, digit, i : integer; PagePosition, InchPerPage : real; begin DotCommand := ''; for i := 1 to 3 do DotCommand := DotCommand + UpCase(docLine[i]); i := 2; Num := 0; repeat i := i + 1; until (docLine[i] in ['0'..'9']) or (i >= length(docLine)); while (i <= length(docLine)) and (docLine[i] in ['0'..'9']) do begin digit := ord(docLine[i]) - ord('0'); Num := Num * 10 + digit; i := i + 1; end; if DotCommand[2] <> '.' then case DotCommand[2] of 'B' : begin {.BP} if Num <> 0 then begin write(lst,chr(27)+'U'+chr(1)) ; Status[uniprt] := true ; end else begin write(lst,chr(27)+'U'+chr(0)) ; Status[uniprt] := false ; end; end; 'L' : begin {.LH} write(lst,chr(27)+'3'+chr(Num * 3)); { NUM * 3 / 144 line spacing} InchPerPage := Page_Length * Line_Spacing / 48.0; PagePosition := Line_Spacing * Line_Num / 48.0; Line_Spacing := Num; Page_Length := round(InchPerPage/Line_Spacing * 48.0); Line_Num := round(PagePosition/Line_Spacing * 48.0); end; 'M' : case DotCommand[3] of 'T' : Top_Margin := Num; 'B' : Bottom_Margin := Num; end; 'P' : case DotCommand[3] of 'L' : Page_Length := Num; 'A' : EndPage; 'C' : begin Page_Col_Num := Num; Footer_Text := ''; for i := 1 to Page_Col_Num {- Page_Offset} do Footer_Text := Footer_Text + ' '; Footer_Text := Footer_Text + Page_Marker; end; 'N' : begin if Num > 0 then Page_Num := Num; Footer_Text := ''; for i := 1 to Page_Col_Num {- Page_Offset} do Footer_Text := Footer_Text + ' '; Footer_Text := Footer_Text + Page_Marker; end; 'O' : begin {Page_Offset} write(lst,chr(27)+'M'+chr(Num)); Page_Offset := Num ; end; 'P' : begin if Num > 0 then Status[3] := on else Status[3] := off; Update_Status_Line(Status); end; end; 'C' : if Line_Num + Num > Page_Length - Bottom_Margin then EndPage; 'H' : case DotCommand[3] of 'E' : begin HE_Status := Def_Status; Header_Text := copy(docLine,4,length(docLine)); end; 'M' : Header_Margin := Num; end; 'F' : case DotCommand[3] of 'O' : begin FO_Status := Def_Status; Footer_Text := copy(docLine,4,length(docLine)); end; 'M' : Footer_Margin := Num; end; 'O' : Footer_Text := ''; end; end;