schweini has asked for the wisdom of the Perl Monks concerning the following question:

Divine ones,

this is kinda OT, but since i think/hope that i'm not the only one who has problems printing HTML-docs, i guess it kinda fits here.

once upon a time, i played around with "html2ps | ps2pdf", but the results weren't quite what i expected.
but now that mozilla's gotten that mature (and overall cool), i was just wondering if anybody knows a way to use mozilla's (very good) printing subsystem for this purpose from a perl scipt (or in any way).
i'm (trying to) code this report-generating system, and my clients want fancy tables, .pdfs, and all that stuff, and i simply refuse to believe that mozilla's code can't be re-used easily somwhow.

thanks for any hints,
-schweini

Replies are listed 'Best First'.
Re: (ab)using mozilla's printing subsystem
by diotalevi (Canon) on Nov 18, 2002 at 03:23 UTC

    While not the mozilla printing system I have some similar problems and I've been pointed to XML-FOP as way to go. At least consider it.

    __SIG__ use B; printf "You are here %08x\n", unpack "L!", unpack "P4", pack "L!", B::svref_2object(sub{})->OUTSIDE;
Re: (ab)using mozilla's printing subsystem
by Anonymous Monk on Nov 18, 2002 at 07:42 UTC
    You can also try the ghostscript library, possibly in conjunction with the Printer module, and of course some module to convert your data into postscript/pdf. If you could put up with simpler formatting, you can create it as pod and then use Pod::PDF. With ghostscript you can also generate output in jpeg/png, which allows you to create a "Print preview" GUI tool with Tk or any toolkity you like. On Win32 I guess you could install a postscript printer dirver and then I guess you coule use OLE to print to postscript with any app. Obviously, for mozilla stuff you'd better ask the mozilla people, but could you pls post here any response you get.