23 Commits

Author SHA1 Message Date
Patrick Kanzler
e814396bd8 refactor: simplified expressions, remove unused import 2016-06-19 12:30:36 +02:00
Patrick Kanzler
910f2fbf2f add with-statement
* with imported from mosquito (adaption of the code in 86a3e8dfb257e3af0ec141ee5d97717501d6e945 by @mosquito)
* encoding of file to utf-8
* added rudimentary test for with
* implement close function for all printers
2016-06-17 23:34:51 +02:00
Patrick Kanzler
471222eda9 Merge pull request #127 from python-escpos/fix/abstractbaseclass-metaclass
FIX abstractbaseclass in Escpos not properly loaded
2016-04-14 00:02:28 +02:00
Michael Billington
a0d8689141 apply fixes, mainly to whitespace ( patch by @patkan in #128 ) 2016-04-13 21:27:51 +10:00
Michael Billington
4584e3138a switch default image format to bitImageRaster
Printers which don't have native QR rendering are less likely to support the newer GS ( L graphics command.
2016-04-06 21:39:46 +10:00
Michael Billington
b45afbb297 add implementation of GS v 0, GS ( L and GS *.
- ported test cases for EscposImage class, copied over 1px and 2px test images from escpos-php
- added test cases over image print function
- updated QR tests to also include image output check
- updated CLI to match new image function options
2016-04-06 07:34:19 +10:00
Michael Billington
59afcf778f remove image handling support 2016-04-06 07:26:00 +10:00
Patrick Kanzler
36debff72c
FIX abstractbaseclass in Escpos not properly loaded
* fixes #126
* adds a test to verify the patch
* uses a helperfunction of six in order to properly load ABCMeta in Python 2 and 3
2016-04-03 22:36:57 +02:00
Patrick Kanzler
2aa0878f54 Merge pull request #123 from python-escpos/refactor/misc-issues
Refactor misc issues
2016-04-03 21:46:15 +02:00
Michael Billington
f39c4227ec Implement printer-side rendering of QR codes for printers that support it.
Expand settings on escpos.qr to include ec, size,
model and 'native' (send image or send esc/pos QR command).

Default is set as native=False, so existing code will continue to
render QR codes as images.
2016-04-03 13:55:52 +10:00
Patrick Kanzler
0121aa0bfb
REFACTOR add PEP8-newlines 2016-04-02 15:29:51 +02:00
Davis Goglin
39da32ca85 Define class vars first in __init__ 2016-03-30 13:38:27 -07:00
Davis Goglin
e545999aa2 Convert class methods to static 2016-03-30 13:38:03 -07:00
Davis Goglin
3017c14df2 Add future imports 2016-03-30 13:31:21 -07:00
Davis Goglin
39165fcb41 Fix tests I just wrote then broke 2016-03-28 15:21:16 -07:00
Davis Goglin
cabb2c930a Add docstring to TestCLI class 2016-03-28 15:01:40 -07:00
Davis Goglin
0c3f273fa1 Clear test dir 2016-03-28 14:57:06 -07:00
Davis Goglin
76f300ea18 Fix text argument 2016-03-28 14:51:48 -07:00
Patrick Kanzler
80f6200915
FEATURE disable panel buttons 2016-03-10 16:01:35 +01:00
Patrick Kanzler
5b5c2c0dba TEST extend tests for larger images (grayscale) 2016-03-08 20:07:16 +01:00
Patrick Kanzler
bda7f85346 ADD test for image printing and text
* image printing does not check output
* text test checks output of a very basic string
2016-03-08 20:07:16 +01:00
Patrick Kanzler
d672ca1268
improve packaging and test environment 2016-02-11 18:37:13 +01:00
Patrick Kanzler
3e200a86b9
ADD very basic nosetest 2016-02-10 19:35:24 +01:00