mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-01-12 18:26:17 +03:00
Merge branch 'master' into rm-deprecated-qt
This commit is contained in:
commit
732eb7223f
|
@ -73,15 +73,6 @@ class TestFileTiff(PillowTestCase):
|
|||
ifd.legacy_api = None
|
||||
self.assertEqual(str(e.exception), "Not allowing setting of legacy api")
|
||||
|
||||
def test_size(self):
|
||||
filename = "Tests/images/pil168.tif"
|
||||
im = Image.open(filename)
|
||||
|
||||
def set_size():
|
||||
im.size = (256, 256)
|
||||
|
||||
self.assert_warning(DeprecationWarning, set_size)
|
||||
|
||||
def test_xyres_tiff(self):
|
||||
filename = "Tests/images/pil168.tif"
|
||||
im = Image.open(filename)
|
||||
|
|
|
@ -70,19 +70,6 @@ Deprecated Deprecated Deprecated
|
|||
``IptcImagePlugin.__version__`` ``PixarImagePlugin.__version__``
|
||||
=============================== ================================= ==================================
|
||||
|
||||
Setting the size of TIFF images
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
.. deprecated:: 5.3.0
|
||||
|
||||
Setting the image size of a TIFF image (eg. ``im.size = (256, 256)``) issues
|
||||
a ``DeprecationWarning``:
|
||||
|
||||
.. code-block:: none
|
||||
|
||||
Setting the size of a TIFF image directly is deprecated, and will
|
||||
be removed in a future version. Use the resize method instead.
|
||||
|
||||
ImageCms.CmsProfile attributes
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
|
@ -127,6 +114,14 @@ Qt 4 reached end-of-life on 2015-12-19. Its Python bindings are also EOL: PyQt4
|
|||
Support for PyQt4 and PySide has been removed from ``ImageQt``. Please upgrade to PyQt5
|
||||
or PySide2.
|
||||
|
||||
Setting the size of TIFF images
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
*Removed in version 7.0.0.*
|
||||
|
||||
Setting the size of a TIFF image directly (eg. ``im.size = (256, 256)``) throws
|
||||
an error. Use ``Image.resize`` instead.
|
||||
|
||||
VERSION constant
|
||||
~~~~~~~~~~~~~~~~
|
||||
|
||||
|
|
|
@ -854,7 +854,7 @@ class ImageFileDirectory_v2(MutableMapping):
|
|||
|
||||
# pass 2: write entries to file
|
||||
for tag, typ, count, value, data in entries:
|
||||
if DEBUG > 1:
|
||||
if DEBUG:
|
||||
print(tag, typ, count, repr(value), repr(data))
|
||||
result += self._pack("HHL4s", tag, typ, count, value)
|
||||
|
||||
|
@ -1079,19 +1079,6 @@ class TiffImageFile(ImageFile.ImageFile):
|
|||
"""Return the current frame number"""
|
||||
return self.__frame
|
||||
|
||||
@property
|
||||
def size(self):
|
||||
return self._size
|
||||
|
||||
@size.setter
|
||||
def size(self, value):
|
||||
warnings.warn(
|
||||
"Setting the size of a TIFF image directly is deprecated, and will"
|
||||
" be removed in a future version. Use the resize method instead.",
|
||||
DeprecationWarning,
|
||||
)
|
||||
self._size = value
|
||||
|
||||
def load(self):
|
||||
if self.use_load_libtiff:
|
||||
return self._load_libtiff()
|
||||
|
|
|
@ -9,7 +9,6 @@ PIL is the Python Imaging Library by Fredrik Lundh and Contributors.
|
|||
Copyright (c) 1999 by Secret Labs AB.
|
||||
|
||||
Use PIL.__version__ for this Pillow version.
|
||||
PIL.VERSION is the old PIL version and will be removed in the future.
|
||||
|
||||
;-)
|
||||
"""
|
||||
|
|
Loading…
Reference in New Issue
Block a user