Re: [OT] Printing hardcopy from an application
On Sat, Nov 13, 2004 at 09:13:57PM +0000, Stephen Patterson wrote:
> On Sat, 13 Nov 2004 21:00:20 +0100, David wrote:
> > The solution I've come up with is to rely upon Latex. That is, generate
> > the output text, insert any tex formatting and send this to a temporary
> > file, let "dvips" convert to postscript and pipe this to "lp" or "lpr".
>
> I've used latex before, but that needs to generate a fair number of
> files from your input foo.tex document, so it can be painful making
> sure that none of these overwrite existing files and to clean them all
> up afterwards.
Yes, this is one aspect of latex that has to be considered - and I had
thought about it. If I go this route, I would think that the best way
would be to create temporary files in, perhaps /tmp, with names
determined with mktemp() or mkstemp() or the like.
> groff is neater in this respect, as you can just pipe
> strings into the lpr command.
I hadn't thought about groff. I'll give this some consideration.
Thanks for the input. It may prove to be quite helpful.
Reply to: