Raw (XML) vs Pixel (PDF) Printing?

121 views
Skip to first unread message

Bernie

unread,
Jan 26, 2017, 10:53:40 PM1/26/17
to qz-print
Hi Tres,

For the documents I need to print, I usually receive them in an XML response file which has Base64 strings; my developer currently takes this and converts it over to a PDF file and I print this file using the regular Windows print dialog.

Would I be able to use the Raw method to print the XML response files directly? 

If so,
- would this printing be much faster?
- would I still be able to chain requests and set different number of copies and page sizes (width, height) to send to different printers (zebra, samsung laserjet)?

Thank you!

Tres Finocchiaro

unread,
Jan 26, 2017, 10:59:02 PM1/26/17
to Bernie, qz-print
Our support for xml tags is currently limited to raw data.

https://qz.io/api/qz (search "xmlTag")


This means it will work for the ZPL/EPL style labels, but not for the image style labels.

For now, you'll have to parse out the XML with JavaScript and send it using a Pixel method (probably an image).


--
You received this message because you are subscribed to the Google Groups "qz-print" group.
To unsubscribe from this group and stop receiving emails from it, send an email to qz-print+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Tres Finocchiaro

unread,
Jan 26, 2017, 11:02:12 PM1/26/17
to Bernie, qz-print
In regards to print speed, pixel printing always suffers over raw.  The rasterization and render process is heavy on both CPU and memory.

In regards to PDF over Image, Image should be considerably faster.

In regards to chaining print request, although our looping example doesn't show it, it can easily be modified to use separate printer parameters for each job.

Bernie

unread,
Jan 26, 2017, 11:31:47 PM1/26/17
to qz-print, olim...@gmail.com
Ok, I'll check with my developer to see if we can generate an image instead of the PDF.

I was planning on following the "chaining request" code because it looks like it allows me to print multiple documents at the same time to different printers, so I was planning on sending something like the following using this "chaining request" code.

Document 1:  Zebra, height=3, width=5, copies=1
Document 2  Samsung LaserJet, height=11, width=8.5, copies=4

Would I be able to do the above following the "chaining request" code listed on the QZ site?

What's the benefit of using the "promise loop" code over the "chaining request" code? 

I see it says "Using a Promise Loop, we can defer items (printers, data)", does this mean that if I'm printing 2 different PDF documents it will print better since I can have a delay printing the documents this way there are no issues with printing?

Thank you!

Tres Finocchiaro

unread,
Jan 26, 2017, 11:34:23 PM1/26/17
to Bernie, qz-print
Chain request will be much simpler to code and implement.

Manual Job Chain - Predefined number of jobs
Promise Loop Chain - Unknown/variable number of jobs

In your case, it sounds like you know exactly how many different documents and printers.  That's what I recommend.

--

Bernie

unread,
Jan 27, 2017, 12:08:18 PM1/27/17
to qz-print, olim...@gmail.com
Hi Tres,

With this "silent printing" setup, I don't have to make the image/pdf document open up in the browser first before printing, right?  I can directly send the print data to the printer using the "Print" button I setup on my website?

Thank you!
To unsubscribe from this group and stop receiving emails from it, send an email to qz-print+u...@googlegroups.com.

Tres Finocchiaro

unread,
Jan 27, 2017, 1:03:16 PM1/27/17
to Bernie, qz-print
Correct.​  This is the main purpose of the product.
Reply all
Reply to author
Forward
0 new messages