From 14d91a7915b5b6427ae54a7c9cd136d27f2ceea2 Mon Sep 17 00:00:00 2001 From: belono Date: Tue, 6 Jun 2023 11:54:18 +0200 Subject: [PATCH] Move image dpi setting to writter_options --- src/escpos/escpos.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/escpos/escpos.py b/src/escpos/escpos.py index 598a4ca..c7f6236 100644 --- a/src/escpos/escpos.py +++ b/src/escpos/escpos.py @@ -789,7 +789,6 @@ class Escpos(object): :type center: bool """ image_writer = ImageWriter() - image_writer.dpi = self._dpi() # Image dpi has to match the printer's dpi # Check if barcode type exists if barcode_type not in barcode.PROVIDED_BARCODES: @@ -810,6 +809,7 @@ class Escpos(object): "quiet_zone": 0, # horizontal padding "text_distance": text_distance, "font_size": font_size, + "dpi": self._dpi(), # Image dpi has to match the printer's dpi } )