mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-07-05 20:33:24 +03:00
simplify setting self._size
Co-authored-by: Andrew Murray <3112309+radarhere@users.noreply.github.com>
This commit is contained in:
parent
c0d04e8b34
commit
f9c69deaae
|
@ -361,10 +361,7 @@ class EpsImageFile(ImageFile.ImageFile):
|
||||||
raise OSError(msg)
|
raise OSError(msg)
|
||||||
|
|
||||||
# An "ImageData" size takes precedence over the "BoundingBox".
|
# An "ImageData" size takes precedence over the "BoundingBox".
|
||||||
if imagedata_size:
|
self._size = imagedata_size or (
|
||||||
self._size = imagedata_size
|
|
||||||
else:
|
|
||||||
self._size = (
|
|
||||||
bounding_box[2] - bounding_box[0],
|
bounding_box[2] - bounding_box[0],
|
||||||
bounding_box[3] - bounding_box[1],
|
bounding_box[3] - bounding_box[1],
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user