******* wx.Mask ******* Inheritance diagram for `wx.Mask`: | .. inheritance-diagram:: wx.Mask | Description =========== This class encapsulates a monochrome mask bitmap, where the masked area is black and the unmasked area is white. When associated with a bitmap and drawn in a device context, the unmasked area of the bitmap will be drawn, and the masked area will not be drawn. .. seealso:: `wx.Bitmap `_, `wx.DC.Blit `_, `wx.MemoryDC `_ Derived From ^^^^^^^^^^^^^ * `wx.Object `_ Remarks ^^^^^^^ A mask may be associated with a `wx.Bitmap `_. It is used in `wx.DC.Blit `_ when the source device context is a `wx.MemoryDC `_ with `wx.Bitmap` selected into it that contains a mask. Methods Summary ^^^^^^^^^^^^^^^ * `__init__ <#__init__>`_ Class API ========= Methods ^^^^^^^ .. method:: __init__(bitmap, colour=wx.NullColour) Constructs a mask from a `wx.Bitmap `_ and a `wx.Colour `_ in that bitmap that indicates the transparent portions of the mask. In other words, the pixels in `bitmap` that match `colour` will be the transparent portions of the mask. If no `colour` or an invalid `colour` is passed then ``wx.BLACK`` is used. **Parameters:** * `bitmap` (`wx.Bitmap `_) * `colour` (`wx.Colour `_) | **Returns:** `wx.Mask `_ .. seealso:: `wx.Bitmap `_, `wx.Colour `_