langs a-z
This commit is contained in:
parent
db842d013d
commit
d066446780
11389 changed files with 98361 additions and 1020 deletions
|
|
@ -0,0 +1,4 @@
|
|||
let () =
|
||||
let oc = open_out "/dev/lp0" in
|
||||
output_string oc "Hello world!\n";
|
||||
close_out oc ;;
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
OUTPUT TO PRINTER.
|
||||
PUT UNFORMATTED "Hello world!" SKIP.
|
||||
OUTPUT CLOSE.
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
hello: procedure options (main);
|
||||
put ('Hello world.');
|
||||
end hello;
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
program testprn;
|
||||
uses printer;
|
||||
var i: integer;
|
||||
f: text;
|
||||
begin
|
||||
writeln ( 'Test of printer unit' );
|
||||
writeln ( 'Writing to lst ...' );
|
||||
for i := 1 to 80 do
|
||||
writeln ( lst, 'This is line', i, '.' #13 );
|
||||
close ( lst );
|
||||
writeln ( 'Done.' );
|
||||
{$ifdef Unix }
|
||||
writeln ( 'Writing to pipe ...' );
|
||||
assignlst ( f, '|/usr/bin/lpr −m' );
|
||||
rewrite ( f );
|
||||
for i:= 1 to 80 do
|
||||
writeln ( f, 'This is line ', i, '.'#13 );
|
||||
close ( f );
|
||||
writeln ( 'Done.' )
|
||||
{$endif}
|
||||
end.
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
given open '>', '/dev/lp0' {
|
||||
.say('Hello, World!');
|
||||
.close;
|
||||
}
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
<</PageSize [595 842]>> setpagedevice % set page size to DIN A4
|
||||
/Courier findfont % use Courier
|
||||
12 scalefont setfont % 12 pt
|
||||
28 802 moveto % 1 cm from the top and left edges
|
||||
(Hello world) show % draw the string
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
MyPrinter$ = LPRINT_GetDefaultPrinter()
|
||||
If LPRINT_OpenPrinter(MyPrinter$)
|
||||
If LPRINT_StartDoc("Printing a RC-Task")
|
||||
LPRINT_Print(Chr(27) + "E") ; PCL reset for HP Printers
|
||||
LPRINT_PrintN("Hello World!")
|
||||
LPRINT_NewPage()
|
||||
LPRINT_EndDoc()
|
||||
EndIf
|
||||
LPRINT_ClosePrinter()
|
||||
EndIf
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
Fqsysprt O F 80 printer
|
||||
C except
|
||||
C seton LR
|
||||
Oqsysprt E
|
||||
O 11 'Hello world'
|
||||
|
|
@ -0,0 +1 @@
|
|||
shell$("echo \"Hello World!\" | lpr")
|
||||
|
|
@ -0,0 +1 @@
|
|||
output = "Hello, world."
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
output(.print,25,"lpt1")
|
||||
print = "Hello, world."
|
||||
|
|
@ -0,0 +1 @@
|
|||
open_output_text_file("/dev/lp0").print("Hello World!");
|
||||
|
|
@ -0,0 +1 @@
|
|||
`echo "Hello World!" | lpr`;
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
# Use the default printer queue, with lp(1) or lpr(1).
|
||||
# 1. The system must have a printer queue.
|
||||
# 2. The printer queue must understand plain text.
|
||||
# 3. System V has lp(1). BSD has lpr(1).
|
||||
# CUPS has both lp(1) and lpr(1).
|
||||
#
|
||||
echo 'Hello World!' | lp
|
||||
echo 'Hello World!' | lpr
|
||||
|
||||
# Use a character device.
|
||||
# 1. The device must understand plain text.
|
||||
# 2. You must have write permission for the device.
|
||||
# 3. Some systems have /dev/lp0, /dev/lp1, ...
|
||||
# 4. BSD has /dev/lpt0, /dev/lpt1, ... for the parallel ports;
|
||||
# and /dev/ulpt0, /dev/ulpt1, ... for the USB printers.
|
||||
# Note that intermingling can occur if two processes write to the device at the
|
||||
# same time. Using the print spooler method above avoids this problem,
|
||||
#
|
||||
echo 'Hello World!' >/dev/lp0
|
||||
echo 'Hello World!' >/dev/lpt0
|
||||
echo 'Hello World!' >/dev/ulpt0
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
code Text=12;
|
||||
Text(2, "Hello World!
|
||||
");
|
||||
Loading…
Add table
Add a link
Reference in a new issue