Dyalog Primer - User Interfaces - Printing
'Printer Name' 'Selection' 'Copies' 'Collate',[¯.5] pv
text←3 10⍴'Mary had a little lamp'
pr.⎕NEW'Text'(('Text' text)('Points'(5 0))('FontObj'('Arial' 64)))
junk←pr.⎕NEW'Text'(('Text' text)('Points'(10 0))('FontObj'('Arial' 64)))
junk←pr.⎕NEW'Poly'(('Points'(20(0 100)))('LWidth' 2))
documentation predates Version 11, hence uses an older syntax.
is to select a printer, either by picking from the list of available
printers, or by letting the user pick one (using the RTF printer
- Content is
placed into the (virtual) page by coordinate (percentage is most
operation is forced by Print, or by expunging the printer object.
PrintList RTFPrintSetup Setup (Dyalog Object
- In a new workspace create a form with File/Printer Select and
File/Print Menu items; put an edit control onto the form and populate
it with a (large) character matrix read from file.
- The Printer
Select menuitem should open a printer selection dialogue and store the
selected printer name to a variable (you could use a global, but it's
tidier to have the variable defined within the form's namespace)
Print menuitem should print as many pages as are needed for the content
of the edit control. each page should have a header (containing
"Page n of m") and a footer ("Printed on ddmmmyyyy at hh:mm:ss).
The header and footer should be separated from the main page body
by horizontal lines.
- Add a graphic image to your form
the printing functionality so that the graphic image also appears on
the printed page, right-justified between the header and the main body.