summaryrefslogtreecommitdiff
path: root/system/std.zusatz/1.7.3/src/MINPRINT.ELA
diff options
context:
space:
mode:
Diffstat (limited to 'system/std.zusatz/1.7.3/src/MINPRINT.ELA')
-rw-r--r--system/std.zusatz/1.7.3/src/MINPRINT.ELA94
1 files changed, 94 insertions, 0 deletions
diff --git a/system/std.zusatz/1.7.3/src/MINPRINT.ELA b/system/std.zusatz/1.7.3/src/MINPRINT.ELA
new file mode 100644
index 0000000..a0bd44a
--- /dev/null
+++ b/system/std.zusatz/1.7.3/src/MINPRINT.ELA
@@ -0,0 +1,94 @@
+PACKET minimal font routines DEFINES lf height of current font,
+ x factor per inch,
+ y factor per inch:
+
+REAL CONST lf height of current font :: 2.54 / 6.0;
+INT CONST x factor per inch :: 10,
+ y factor per inch :: 6;
+
+END PACKET minimal font routines;
+
+PACKET minimal printer (* 25.04.84 *)
+ DEFINES material,
+ start,
+ new page,
+ reset printer,
+ line,
+ print text ,
+ printer cmd,
+ on,
+ off,
+ x pos,
+ y pos,
+ papersize,
+ limit,
+ change type:
+
+
+PROC change type (TEXT CONST name of type): ENDPROC change type;
+
+PROC material (TEXT CONST value): END PROC material;
+
+PROC start (REAL CONST x,y): END PROC start;
+
+PROC papersize (REAL CONST x,y): END PROC papersize;
+
+PROC limit (REAL CONST l): END PROC limit;
+
+PROC on (TEXT CONST cmd): END PROC on;
+
+PROC off (TEXT CONST cmd): END PROC off;
+
+PROC xpos (REAL CONST cm): END PROC xpos;
+
+PROC ypos (REAL CONST cm): END PROC ypos;
+
+PROC printer cmd (TEXT CONST cmd):
+ out (buffer); buffer := "";
+ out(cmd)
+END PROC printer cmd;
+
+INT VAR actual line ;
+
+TEXT VAR buffer;
+
+PROC reset printer:
+ buffer := "";
+ actual line := 0
+ENDPROC reset printer;
+
+PROC print text (TEXT CONST content, INT CONST mode):
+ buffer CAT content
+ENDPROC print text;
+
+PROC new page:
+ IF buffer <> ""
+ THEN line (1.0)
+ FI;
+ actual line := actual line MOD 72 ;
+ IF actual line > 0
+ THEN page feed
+ FI .
+
+page feed :
+ INT VAR i ;
+ FOR i FROM actual line UPTO 71 REP
+ out(" "13""10"")
+ PER ;
+ actual line := 0
+
+ENDPROC new page;
+
+PROC line (REAL CONST lf):
+ out (buffer); buffer := "";
+ IF lf > 0.0
+ THEN REAL VAR ist := 0.0 ;
+ REP
+ out (""13""10"") ;
+ actual line INCR 1 ;
+ ist INCR 1.0
+ UNTIL ist >= floor (lf) PER
+ FI
+ENDPROC line;
+
+ENDPACKET minimal printer;