I'm trying to print a receipt obtained from another system, so the easiest way that I've found is to convert it to an image and print it (the receipt is quite complex, so it cannot be rebuilt as "simple text").
I'm printing it using the PrintImage function, on a Xamarin.iOS app, but I think the same issue apply also to other technologies.
The printer is a ZQ320.
The image's height can be quite variable, due to the number of items that the receipt contains.
When the image is not too high, it is printed correctly.
When it's more than a certain height, instead, it is not printed completely, a part is "truncated".
From the Zebra Printer Setup app I can see that in the media settings the "current media type" is "receipt" and the length parameter was, by default, 1.51 in.
If I increase the length value, e.g. to 10 inch, then the whole image is printed.
Actually the work around to increase the length in the media settings can't be a final solution, because the length of the image is variable.
I've tried to "play" with the PrintImage overloads, but I didn't get any result.
I tried also to change the "media.feed_length" setting using the SetSetting function, but it didn't work as well.
The only solution that, at the moment, worked, was to "embed" the image in a ZPL file and then use the ^LL parameter to specify a certain height (and I have yet to understand to which value I should set the height, I didn't explore this option too deep yet).
The question is: is there a better method to print these images, without recurring to the ZPL workaround?
And another question is: I've seen that functions such as PrintImage and StoreImage, in the documentations, warn about some OutOfMemory exceptions that could be thrown with images e.g. bigger than 1024x768. In my case I cannot exclude to have images bigger than these limits. Should I use other ways to send the image to the printer?