squeak printing?

John M McIntosh johnmci at smalltalkconsulting.com
Mon Feb 11 04:40:57 UTC 2002


Well after a wee bit of programming and considerable hassle fellow 
macintosh squeakers can find attached the macintosh plugin for 
printing in carbon classic.

If you have a classic carbon VM, say Squeak Carbon VM 3.0.5 or 
higher, but not the mach-o vm you can use the class posted earlier on 
saturday to print from squeak on mac OS 8.6 or higher with carbonlib 
1.5.

Perhaps system 8.1 or higher might work with carbonlib 1.0.4 
installed. However I used CarbonLib 1.5 to build this and would be 
curious if it works on pre 8.6 systems.

Hint. testing this a wide variation of printers would be good, mm 
even testing in landscape would be good too. I was happy just to 
splash a red square on paper.

Now the few mac programmers out there might dig in and tell me why 
the PixMap we built in Squeak silent fails to produce bits when you 
CopyBit the PixMap to the printer grafport. Fixing this requires 
building a NewGWorld and doing a double copy from the PixMap to 
GWorld to printer grafport. Yet the original faulty code work just 
fine under OS-X 10.1.2 which leads to a bit of hair pulling. Same 
code is used for the display logic and is ancient in flavor. See 
sqMacWindow.c for clues.

Oh and if your kid's color printer doesn't have the yellow ink jet 
working, then printing red squares will always get you purple and a 
few hours of muttering about color tables and translations until you 
realize there is a hardware problem.

PS I might consider non-carbon pre os8.6 support, but maybe I'll wait 
a bit to flesh out the interface and classes first. Besides I've 
heard that's more difficult to work in buy apple has provided an 
updated sample that clarify a few things, and I'd like to get the 
postscript stuff to work first too.
-- 
--
===========================================================================
John M. McIntosh <johnmci at smalltalkconsulting.com> 1-800-477-2659
Corporate Smalltalk Consulting Ltd.  http://www.smalltalkconsulting.com
===========================================================================
-------------- next part --------------
A non-text attachment was scrubbed...
Name: PrintJobPlugin.sit
Type: application/mac-binhex40
Size: 9092 bytes
Desc: not available
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20020210/da8164a8/PrintJobPlugin.hqx


More information about the Squeak-dev mailing list