Commit Graph

76 Commits

Author SHA1 Message Date
Eric Soroos
27bc13df7b typos 2017-12-20 12:34:42 +00:00
Eric Soroos
e5ff9db407 typo 2017-12-20 11:46:01 +00:00
Eric Soroos
25d961238c Added sRGB and cHRM chunks to PngInfo, added tests for #2782 2017-12-20 11:35:11 +00:00
Roland Netzsch
1cf2deba3b Fix #2782 2017-12-20 11:31:23 +00:00
wiredfool
d42b57cf1e
Merge pull request #2873 from radarhere/debugging
Removed debugging code
2017-12-19 15:52:49 +00:00
Jon Dufresne
8844e2dd71 Make PngImagePlugin.add_text() zip argument type bool
Always used as a bool, but was previously defined as 0/1. Use modern
idiomatic Python by using the bool type for bool arguments.
2017-12-16 09:13:45 -08:00
Andrew Murray
f6e4997919 Removed debugging code 2017-11-24 21:34:58 +11:00
Andrew Murray
97662294f0 Added context manager support 2017-10-07 23:18:23 +11:00
Andrew Murray
1856d106ea Corrected parameters in documentation 2017-09-29 21:08:49 +10:00
Alexander
a26a584812 Do not raise SyntaxError for wrong chunks (just ignore them) 2017-05-23 18:00:15 +03:00
Andrew Murray
798fde57ca Removed unused imports 2017-03-03 21:38:19 +11:00
Hugo
cb34b686a5 Merge pull request #1822 from radarhere/unused
Remove unused imports
2017-02-26 10:05:19 +02:00
Andrew Murray
f0480de118 Restricted PNG encoderinfo chunks to valid values when saving 2017-01-21 16:57:03 +11:00
Andrew Murray
361f579579 Moved iCCP chunk before PLTE chunk when saving as PNG 2017-01-21 13:32:22 +11:00
Andrew Murray
97a2d42dac Removed unused print_function imports 2017-01-18 20:06:21 +11:00
Andrew Murray
58b5c9187d Replaced absolute PIL imports with relative imports (#2349) 2017-01-17 13:22:18 +00:00
Tim Graham
792df283d9 Fix "invalid escape sequence" bytestring warnings in Python 3.6 2016-10-31 11:48:59 -04:00
Jon Dufresne
7992d2a65a Fix BytesWarning discovered while running tests
Discovered using the command:

python -b -m nose -vx Tests/test_*.py
2016-10-22 12:35:44 -07:00
Andrew Murray
d3d29ab2e3 Use truth value when checking for optimize option on save 2016-09-25 21:20:54 +10:00
Alexander Karpinsky
639bdd3c02 Merge pull request #1991 from kkopachev/png-crc-error-ignore
Ability to skip crc checks for ancillary chunks
2016-06-30 17:25:04 +04:00
Konstantin Kopachev
885297d21f
Fix python 3 bytes to string concat error 2016-06-29 14:44:29 -07:00
wiredfool
0ddb0f3c7f Merge pull request #1970 from uploadcare/ignore-decompression-dos
Ignore large text blocks in PNG if LOAD_TRUNCATED_IMAGES is enabled
2016-06-29 22:32:35 +01:00
Konstantin Kopachev
c3b970f046
Ability to skip crc checks for ancillary chunks 2016-06-29 12:24:37 -07:00
wiredfool
6a3acde001 Merge pull request #1909 from uploadcare/png-icc-profile
Get ICC profile from `encoderinfo` while PNG saving
2016-06-25 11:01:53 +01:00
homm
95402143fe ignore large text blocks in PNG if LOAD_TRUNCATED_IMAGES is enabled 2016-06-20 17:33:10 +03:00
Andrew Murray
86828ffd2a Replaced del with pop 2016-06-18 11:25:39 +10:00
homm
989e162ff6 save icc profile from encoderinfo 2016-05-12 20:28:42 +03:00
Oliver Tonnhofer
c773688f37 improve simple palette detection for PNG
- reverts change #1239 which could remove transparency from valid images
  (see test_save_p_transparent_black test case)
- improves simple palette detection to handle images from #1238
2016-04-19 10:21:53 +02:00
wiredfool
90378c8298 Fixing compatibility with the truncated images tests 2016-04-04 05:40:37 -07:00
wiredfool
77da73c90f Catch struct.errors when verifying png files, convert to SyntaxErrors, fixes #1755 2016-04-04 03:08:22 -07:00
Andrew Murray
d21430234e Improved consistency of checks for flush 2015-09-02 23:48:22 +10:00
Andrew Murray
c6b13d294f Flake8 fixes 2015-08-25 22:27:18 +10:00
Andrew Murray
fa73879d19 Changed register calls to use format property 2015-07-04 23:29:58 +10:00
Antony Lee
4e754e9c55 Use logging instead of print.
cf. #1191.

Only TiffImagePlugin and OLEFileIO still rely on (their own) DEBUG flag.
I left TiffImagePlugin as it is because I hope #1059 gets merged in
first, and OLEFileIO because it uses its own logic.

Untested, as usual.
2015-06-29 12:39:50 -07:00
Hugo
b350a2ac95 Merge pull request #1239 from juztin/master
Setting transparency value to 0 when the tRNS contains only null byte(s)
2015-05-27 22:37:29 +03:00
Andrew Murray
3c7e37d2d7 Replaced old-style classes 2015-05-27 00:07:21 +10:00
Justin Wilson
e317a729f3 Setting transparency value to 0 when the tRNS contains only null byte(s) 2015-05-22 16:37:50 -06:00
Andrew Murray
d1c182cadc Various Flake8 fixes 2015-04-24 09:26:52 +10:00
hugovk
0b79c6e24a Remove unreachable code (if 0) 2015-03-05 21:07:16 +02:00
wiredfool
0b75526ffe Limit total text chunk size to 64k 2014-12-29 17:10:27 -08:00
wiredfool
44286ba3c9 Fix for zlib.decompression bomb in iTXt,zTXt, and iCCP chunks 2014-12-28 22:49:52 -08:00
wiredfool
c770984867 Document all the save params for PNG, and their references [ci skip] 2014-11-19 15:35:33 -08:00
Hugo
ae7b765b53 Fix some Landscape.io errors and warnings 2014-10-01 16:50:33 +03:00
hugovk
8de95676e0 flake8 2014-08-26 16:47:10 +03:00
Fredrik Tolf
a9f4e30641 Save detected non-Latin1 characters as iTXt to preserve them. 2014-07-23 07:43:52 -07:00
Fredrik Tolf
c469dd9ae5 Added support for encoding and decoding iTXt chunks. 2014-07-23 00:28:44 -07:00
hugovk
14c2f86873 Rename bytes variable as read_bytes to avoid the built-in function name. 2014-05-21 21:33:49 +03:00
hugovk
d594c0241a Rename len variables as length to avoid the built-in function name. 2014-05-21 20:45:02 +03:00
wiredfool
f8ce951a2d Merge Changes from master 2014-03-04 22:41:36 -08:00
David Schmidt
6457eed2cb overwrite redundant Image palette with new ImageCore Palette after quantize, fixes #513 2014-03-04 21:44:32 -08:00