diff --git a/docs/reference/Image.rst b/docs/reference/Image.rst index 2613b6585b3..ed37521fdae 100644 --- a/docs/reference/Image.rst +++ b/docs/reference/Image.rst @@ -123,6 +123,7 @@ methods. Unless otherwise stated, all methods return a new instance of the .. automethod:: PIL.Image.Image.alpha_composite +.. automethod:: PIL.Image.Image.apply_transparency .. automethod:: PIL.Image.Image.convert The following example converts an RGB image (linearly calibrated according to diff --git a/docs/releasenotes/9.2.0.rst b/docs/releasenotes/9.2.0.rst index eddbd07a2d7..424fd487a29 100644 --- a/docs/releasenotes/9.2.0.rst +++ b/docs/releasenotes/9.2.0.rst @@ -57,10 +57,13 @@ TODO API Additions ============= -TODO -^^^^ +Image.apply_transparency +^^^^^^^^^^^^^^^^^^^^^^^^ -TODO +Added :py:meth:`~PIL.Image.Image.apply_transparency`, a method to take a P mode image +with "transparency" in ``im.info``, and apply the transparency to the palette instead. +The image's palette mode will become "RGBA", and "transparency" will be removed from +``im.info``. Security ========