mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-08-26 07:04:45 +03:00
Type annotations: Enable Image.filter to also accept Callable returning Filter.
This commit is contained in:
parent
cb535be9af
commit
0541e239d4
|
@ -1184,7 +1184,7 @@ class Image(object):
|
||||||
return self._new(self.im.expand(xmargin, ymargin, 0))
|
return self._new(self.im.expand(xmargin, ymargin, 0))
|
||||||
|
|
||||||
def filter(self, filter):
|
def filter(self, filter):
|
||||||
# type: (Filter) -> Image
|
# type: (Union[Filter, Callable[[], Filter]]) -> Image
|
||||||
"""
|
"""
|
||||||
Filters this image using the given filter. For a list of
|
Filters this image using the given filter. For a list of
|
||||||
available filters, see the :py:mod:`~PIL.ImageFilter` module.
|
available filters, see the :py:mod:`~PIL.ImageFilter` module.
|
||||||
|
|
Loading…
Reference in New Issue
Block a user