diff --git a/escpos/constants.py b/escpos/constants.py index 0d7d8c6..7511365 100644 --- a/escpos/constants.py +++ b/escpos/constants.py @@ -21,6 +21,7 @@ PAPER_PART_CUT = '\x1d\x56\x01' # Partial cut paper TXT_NORMAL = '\x1b\x21\x00' # Normal text TXT_2HEIGHT = '\x1b\x21\x10' # Double height text TXT_2WIDTH = '\x1b\x21\x20' # Double width text +TXT_4SQUARE = '\x1b\x21\x30' # Quad area text TXT_UNDERL_OFF = '\x1b\x2d\x00' # Underline font OFF TXT_UNDERL_ON = '\x1b\x2d\x01' # Underline font 1-dot ON TXT_UNDERL2_ON = '\x1b\x2d\x02' # Underline font 2-dot ON diff --git a/escpos/escpos.py b/escpos/escpos.py index 72d1b3a..2208e30 100644 --- a/escpos/escpos.py +++ b/escpos/escpos.py @@ -234,8 +234,8 @@ class Escpos: """ Set text properties """ # Width if height == 2 and width == 2: - self._raw(TXT_2WIDTH) - self._raw(TXT_2HEIGHT) + self._raw(TXT_NORMAL) + self._raw(TXT_4SQUARE) elif height == 2 and width != 2: self._raw(TXT_NORMAL) self._raw(TXT_2HEIGHT) @@ -254,7 +254,6 @@ class Escpos: elif type.upper() == "U2": self._raw(TXT_BOLD_OFF) self._raw(TXT_UNDERL2_ON) - self._raw(TXT_ITALIC_OFF) elif type.upper() == "BU": self._raw(TXT_BOLD_ON) self._raw(TXT_UNDERL_ON)