🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.mac
Article #25348

Re: Printing stuff in Lightspeed C

#25348
From: leonardr
Date: Mon, 15 Feb 1988 17:48
36 lines
2576 bytes
thompson@uxf.cso.uiuc.edu(??) writes in comp.sys.mac

>I am porting a C program from the IBM to the Mac.  I know it will look
>and feel strange on the Mac, but the primary objective at this point
>is to get it *functional*.
>
>Unfortunately, the C from which I am porting has a library function,
>stdprn, which is the standard printer port (accessed like a file).
>The C to which I am porting (Lightspeed v2.11) does not.  In fact,
>in all the documentation and examples, I am told I must open a grafport
>and draw my text into it before I can get things to print out.
>
>All I want to do is send lines of text to the printer.  Without opening
>grafports or drawing text (this program makes no other use of that stuff,
>of course).  Is there no way to do this?
	The answer to your question is: Yes.  You can stream text out to a 
printer just like on non-Mac machines, however doing so is not recommend by
the powers that be (The Apple Thought Police and their Development Group). Your
best bet is to do it the proper way by using the printing manager and using all
the grafport and drawing of text that you refer to.  This is the proper method
for printing on the Mac and it guarentees that you can print to ANY attached
printer instead of just the ImageWriter (which is what text streaming will get
you).


+---------------------------------+-----------------------------------+
+                                 +  Any thing I say may be taken as  +
+   Leonard Rosenthol             +  fact, then again you might decide+
+   President, LazerWare, inc.    +  that it really isn't, so you     +
+                                 +  never know, do you??             +
+   leonardr@uxe.cso.uiuc.edu     +                                   +
+   GEnie:  MACgician             +                                   +
+   Delphi: MACgician             +                                   +
+                                 +                                   +
+---------------------------------+-----------------------------------+
Technical Details
Message-ID: <46100078@uxe.cso.uiuc.edu>
Path: arc1-ca.pugleaf.net!utzoo!mnetor!uunet!husc6!bloom-beacon!gatech!purdue!i.cc.purdue.edu!j.cc.purdue.edu!pur-ee!uiucdcs!uxc.cso.uiuc.edu!uxe.cso.uiuc.edu!leonardr
References: <46700008@uxf.cso.uiuc.edu>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!mnetor!uunet!husc6!bloom-beacon!gatech!purdue!i.cc.purdue.edu!j.cc.purdue.edu!pur-ee!uiucdcs!uxc.cso.uiuc.edu!uxe.cso.uiuc.edu!leonardr
From: leonardr@uxe.cso.uiuc.edu
Newsgroups: comp.sys.mac
Subject: Re: Printing stuff in Lightspeed C
Message-ID: <46100078@uxe.cso.uiuc.edu>
Date: 15 Feb 88 17:48:00 GMT
References: <46700008@uxf.cso.uiuc.edu>
Lines: 36
Nf-ID: #R:uxf.cso.uiuc.edu:46700008:uxe.cso.uiuc.edu:46100078:000:2029
Nf-From: uxe.cso.uiuc.edu!leonardr    Feb 15 11:48:00 1988