in reply to Line Printing Control

I wouldn't go the way of PCL but rather the way of Postscript, together with any template toolkit that isn't HTML specific (that leaves TT2 from what I see, but I don't know whether one couldn't abuse HTML::Template). This should take care of the layout side.

For the printing process, either have Postscript capable printers (you most likely already have, as you are under Linux), or use Ghostscript on any box to handle the ugly details of converting Postscript to something printable on your printer of choice.

I personally would turn to TeX for the superior layout quality (and ease of producing PDFs), but Postscript should be as readable as (La)TeX, if not more.

perl -MHTTP::Daemon -MHTTP::Response -MLWP::Simple -e ' ; # The $d = new HTTP::Daemon and fork and getprint $d->url and exit;#spider ($c = $d->accept())->get_request(); $c->send_response( new #in the HTTP::Response(200,$_,$_,qq(Just another Perl hacker\n))); ' # web

Replies are listed 'Best First'.
Re: Re: Line Printing Control
by dsheroh (Monsignor) on Feb 13, 2003 at 22:25 UTC
    To what degree and in what ways are template toolkits made HTML (or other language) specific? I know that, despite its name, CGI::FastTemplate is completely content-agnostic and I've used it to generate TeX output without having to resort to abuse.

      I haven't worked with any of the template toolkits, but I imagine that the HTML oriented toolkits might implement automagic HTML entity quoting, which would get in the way or at least be inconvenient. Also, such toolkits might expect to be able to parse their templates with HTML::Parser, or expect their templates to be valid XML / XHTML, except for their own special tags. Some toolkits even bear HTML in their name, which suggests that they cater specifically to HTML output (HTML::Template and HTML::Mason).

      But as I said, I didn't work with any of the toolkits, so this remains to be evaluated by the actual user.

      perl -MHTTP::Daemon -MHTTP::Response -MLWP::Simple -e ' ; # The $d = new HTTP::Daemon and fork and getprint $d->url and exit;#spider ($c = $d->accept())->get_request(); $c->send_response( new #in the HTTP::Response(200,$_,$_,qq(Just another Perl hacker\n))); ' # web