I'm using a Zebra Technologies ZTC ZT230-300dpi ZPL printer to push an image via network to the printer. I have a Word template that I convert to HTML using OpenXMLPowerTools, then to an image using CoreHtmlToImage, and finally to ZPL using Zplify.
I am going through these multiple conversion steps because I couldn't find any direct method to convert a Word document to ZPL.
Here's the issue:
- When I convert the Word document to HTML, the font family remains intact.
- After converting the HTML to an image and then to ZPL, the font style still appears correct when I verify using an online viewer or a virtual ZPL printer.
- However, when I push the ZPL code to the actual printer, the font family does not match the original Word document.
Has anyone encountered a similar issue or have any suggestions on how to retain the font family correctly in the final printed output? Any tips or alternative approaches for converting a Word document to ZPL with the correct font styling would be greatly appreciated.
Thank you!
I'm using the below code, to send the command to printer.
var converter = new ZplImageConverter() { InterpolationMode = InterpolationMode.HighQualityBicubic };
var zplCommand = converter.BuildLabel(bitmap);
printerSocket.Send(Encoding.ASCII.GetBytes(zplCommand));
Is the font changing because it gets expanded when converting to an image before sending it to the printer? Could this be the issue affecting the font family?
I couldn't find any direct method to convert a Word document to ZPL- have you tried opening it in Word and printing to that printer? Other than that, the printer would absolutely not try to alter an image, if you are sending an image, so if your fonts look off in the image, that must have happened at the stage where you converted the HTML to image. Are you sure it's a font family issue though, and not threshold effects due to no/insufficient dithering in your image?