[enh] send to printer from a workspace

David T. Lewis lewis at mail.msen.com
Sat Mar 11 13:32:09 UTC 2000


On Fri, Mar 10, 2000 at 11:24:28AM -0800, Dan Ingalls wrote:
> Doug Way <dway at mat.net> wrote...
> >I guess if this printing code only works on Windows (so far), maybe the
> >print command shouldn't be added to the text menu just yet in the base
> >image.  Although on the other hand, having the menu item there might
> >provide extra incentive for folks to implement the primitive on Mac/Unix.
> 
> I have printed from a Mac -- well -- I've used the code to write a ps file, and then sent it to the printer with DropPS.  Don't know how to send it directly yet.  If someone does, that would be a great service.
> 
> 	- Dan
> 

As a general approach, writing output directly to a printer is to be
avoided.  In many environments, printers are shared devices which are
accessed indirectly through print queuing software or network services.
The more general approach is to package the print output (presumably
as Postscript) and hand it off to a print server, possibly external
to Squeak.  On a Unix box, the print server might be a program called
"/usr/bin/lpr".  On Windows or Mac, in might be some other mechanism.
In the special case of a single user environment with a physically
attached printer and no printer handling software, it might be some
code in Squeak that calls ioFormPrint() to drive the printer device
directly.

Dave





More information about the Squeak-dev mailing list