adjust import order and fix `qr` method

This commit is contained in:
freeyoung 2014-03-14 01:58:55 +08:00
parent b68b3dc6c0
commit 9f7e5861cd
1 changed files with 5 additions and 5 deletions

View File

@ -6,9 +6,9 @@
@license: GPL
'''
import qrcode
import time
import os
import time
import qrcode
import operator
from PIL import Image
@ -147,9 +147,9 @@ class Escpos:
qr_code.add_data(text)
qr_code.make(fit=True)
qr_img = qr_code.make_image()
im = qr_img._img.convert("RGB")
# Convert the RGB image in printable image
self._convert_image(im)
im = qr_img._img.convert("RGB")
self.image(im)
def barcode(self, code, bc, width, height, pos, font):
""" Print Barcode """