Closed Lophophanes closed 2 years ago
This is very timely. I have been testing the Print Daemon for two purposes: (1) 80 x 297 mm hold slip printing, and (2) A5 printing for Resource Sharing printouts. I've only just started on (1), with an Epson TM series thermal printer. Initial problem is that the printout comes out shrunk to about 50% of the size. Looking at main.js
for v2 beta, I think perhaps this is because the page size is hard-coded to Letter
. Would be great if this and more options, for example, the left & right margins, were exposed in the GUI's printer profiles.
Format and border options added in release 2.0.0-beta-03.
Format and border options added in release 2.0.0-beta-03.
@mgobat This is great. Thank you! I have managed to print something that looks okay-ish on our Epson thermal POS printer using letterFormat":"A5","borderUnits":"mm","borderTop":"4","borderRight":"6","borderBottom":"4","borderLeft":"6"
config. The printout font size is a touch on the small size though. I tried A6 and this was the right size font, but a massive gap is present in the middle of the printout. Also, due to using these fixed paper sizes there's quite a bit of wasted paper at the top.
I am wondering whether it would be possible to allow non-standard sizes to be passed through; the paper size I'm aiming for is Roll Paper 80 x 297 mm
. Looking at the readme for node-html-pdf
it looks like there's either the option of format and orientation (supported by the Alma Print Daemon), OR width and height (which I think is what is needed here).
Hi,
Most of our libraries also use 80 mm thermal rolls so @Jimadine request would be very helpful for us at well. Perhaps it would also be useful to have the option of bypassing any paper size formatting in the daemon and use the printer default settings.
Regards,
Helgi
@kremke I ended up creating my own solution for this. It's not perfect but we're now using it in three settings where there is a workflow involved and it's working well. All of my initial work on this was testing with an Epson TM-T88III USB printer. The only change needed to the printer's Printing Preferences was to scale the printouts to 70%:
EDIT: this reminded me of an issue when using scaling; the HTML doesn't expand to the full width of the paper, so wrapping occurs, and more paper roll is used than necessary. Instead, I turned off scaling and added a CSS rule to the XSL template to reduce the font-size. The result is this:
(a slight improvement compared with the scaled printout)
Version 2.0.0 includes additional formatting options. Please open new issues if additional options are needed.
Hello, Our objective : in an ecological concern and also as a measure of financial savings, we would like to reduce the size of the prints to use less paper.
Our new feature request : in the future, is it planned to be able to print in A5 format ?
Best regards,