[comp.sys.ibm.pc] Wanted: Print help

troj@umaxc.weeg.uiowa.edu (12/09/89)

Does anyone have source code for a program even vaguely resembling the
DOS print command?  Specifically, I need a TSR to do background printing.

For quite a few months, I've wanted to make some major hacks to print,
and haven't had the time.  Now that I've got the time, I'd rather like to
avoid recreating the portion of print which actually handles grabbing CPU
time and sending information to the printer, if it can be avoided.

-Kevin Trojanowski
 troj@umaxc.weeg.iuowa.edu
 trojpg@uiamvs.bitnet

PS:  My roommate and I have checked Simtel20, and haven't found anything
resembling what I need.

keating@rex.cs.tulane.edu (John W. Keating) (12/09/89)

In article <276@ns-mx.uiowa.edu> troj@umaxc.weeg.uiowa.edu () writes:
>Does anyone have source code for a program even vaguely resembling the
>DOS print command?  Specifically, I need a TSR to do background printing.
>
    Have you thought about using a print spooler??  This tends to take up
some memory, but is very effective for me.
-- 
******************************************************************************
* Internet: keating@rex.cs.tulane.edu * /==     Tulane           *          *
* Usenet:   ...!pyramid!rex!keating   *   ====      Green        * John     *
* Bitnet:   cs6hecu@tcsvm             *    ======       Wave!!   *  Keating *
* CIS:      Hmmm...  cantremember...  *   ===========            *          *
*****************************************************************************

press@venice.SEDD.TRW.COM (Barry Press) (12/12/89)

In article <276@ns-mx.uiowa.edu> troj@umaxc.weeg.uiowa.edu () writes:
>Does anyone have source code for a program even vaguely resembling the
>DOS print command?  Specifically, I need a TSR to do background printing.

You haven't found anything because it's already there in DOS.  If you look
in a good 3rd party DOS tech reference (e.g., MSDOS Encyc.), there is
a function in the multiplex interrupt that lets you hook into the spooler
code in DOS -- it's what print uses.  You can hand it files, etc.
-- 
Barry Press                                 Internet: press@venice.sedd.trw.com

troj@umaxc.weeg.uiowa.edu (Kevin Trojanowski) (12/12/89)

In article <1630@rex.cs.tulane.edu> keating@rex.UUCP (John W. Keating) writes:
>In article <276@ns-mx.uiowa.edu> troj@umaxc.weeg.uiowa.edu () writes:
>>Does anyone have source code for a program even vaguely resembling the
>>DOS print command?  Specifically, I need a TSR to do background printing.
>>
>    Have you thought about using a print spooler??  This tends to take up
>some memory, but is very effective for me.

This doesn't quite accomplish want I want; my specific aim is to write create
a program similar to print which allows setting of margins, page length,
fonts (probably for an LQ-850; Laserjet a future addition), and other such
goodies typically found on spoolers on minis and mainframes.

The addition of a print spooler at a future date may also be done.  Granted,
this will probably produce a good-sized TSR, but I'd rather burn memory than
tie up my computer just because I need a 100+ page printout...

-Kevin Trojanowski
 troj@umaxc.weeg.uiowa.edu
 trojpg@uiamvs.bitnet

timothym@tekigm2.MEN.TEK.COM (Timothy D Margeson) (12/12/89)

Norton's LP command allows you to set margins, headers and footers when
printing text files.

Use the LP command in conjunction with a spooler for reasonable printer
control and convienence.
-- 
Tim Margeson (206)253-5240
PO Box 3500  d/s C1-022                          @@   'Who said that?'  
Vancouver, WA. 98668
e-mail replies to: timothym@tekigm2.MEN.TEK.COM

richard@calvin.spp.cornell.edu (Richard Brittain) (12/12/89)

In article <287@ns-mx.uiowa.edu> troj@umaxc.weeg.uiowa.edu (Kevin Trojanowski) writes:
>This doesn't quite accomplish want I want; my specific aim is to write create
>a program similar to print which allows setting of margins, page length,
>fonts (probably for an LQ-850; Laserjet a future addition), and other such
>goodies typically found on spoolers on minis and mainframes.
>
 It sounds like you are actually writing a formatting program, not a background
print spooler (which is all that print is, doing no manipulation of the document
at all).  Why don't you process the input file, producing the file full of
printer codes etc., and place it in a spool directory.  Then pass the filename
to print.com (which is already loaded of course) and you are home.

The only problem is that it will fail if the printer formatting codes happen
to include a control-Z !!!!! (thanks IBM, or was it microsoft)

I have been doing this for some time with a hacked *roff clone, and I also
recently hacked a "sideways" program to do the same thing.  The time taken
to format is always very much less then the time to print, at least on any
dot matrix printer.  To find out how to pass a filename direct to print
look up interrupt 2Fh.    Even easier, get lpr-lpq3.arc from simtel20

Richard Brittain,                   School of Elect. Eng.,  Upson Hall   
                                    Cornell University, Ithaca, NY 14853
ARPA: richard@calvin.spp.cornell.edu	
UUCP: {uunet,uw-beaver,rochester,cmcl2}!cornell!calvin!richard