2013-10-14 09:19:12 +04:00
|
|
|
.. py:module:: PIL.ImageWin
|
|
|
|
.. py:currentmodule:: PIL.ImageWin
|
|
|
|
|
2020-06-22 06:52:50 +03:00
|
|
|
:py:mod:`~PIL.ImageWin` Module (Windows-only)
|
|
|
|
=============================================
|
2013-10-14 09:19:12 +04:00
|
|
|
|
2020-06-22 06:52:50 +03:00
|
|
|
The :py:mod:`~PIL.ImageWin` module contains support to create and display images on
|
2013-10-14 09:19:12 +04:00
|
|
|
Windows.
|
|
|
|
|
|
|
|
ImageWin can be used with PythonWin and other user interface toolkits that
|
|
|
|
provide access to Windows device contexts or window handles. For example,
|
|
|
|
Tkinter makes the window handle available via the winfo_id method:
|
|
|
|
|
|
|
|
.. code-block:: python
|
|
|
|
|
|
|
|
from PIL import ImageWin
|
|
|
|
|
|
|
|
dib = ImageWin.Dib(...)
|
|
|
|
|
|
|
|
hwnd = ImageWin.HWND(widget.winfo_id())
|
|
|
|
dib.draw(hwnd, xy)
|
|
|
|
|
|
|
|
|
|
|
|
.. autoclass:: PIL.ImageWin.Dib
|
|
|
|
:members:
|
|
|
|
|
|
|
|
.. autoclass:: PIL.ImageWin.HDC
|
2019-04-21 16:28:08 +03:00
|
|
|
:members:
|
|
|
|
|
2013-10-14 09:19:12 +04:00
|
|
|
.. autoclass:: PIL.ImageWin.HWND
|
2019-04-21 16:28:08 +03:00
|
|
|
:members:
|